In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-03-31 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)06/01 Report--
I. the number of connections:
View the current number of connections
Select count () from v$process
View the maximum number of connections set (the default is 150):
Select value from v$parameter where name = 'processes'
Modify the maximum number of connections
Alter system set processes = 300scope = spfile
Second, query the table space:
Select tablespace_name from user_tablespaces
View the data files corresponding to all tablespaces:
Select tablespace_name,file_name from dba_data_files
Query the login table space:
Select default_tablespace from dba_users where username=' login user'
4. View all table spaces and table space sizes:
Select tablespace_name, sum (bytes) / 1024 / 1024 as MB from dba_data_files group by tablespace_name
View the size of the temporary tablespace:
Select tablespace_name,file_id,file_name,bytes/1024/1024 as "space (MB)"
From dba_temp_files
Where tablespace_name = 'TEMP'
5. Query all tables under the user
Select * from all_tables where owner='TEST'; (TEST is the user name, the user name must be uppercase. )
View the table of currently logged-in users:
Select table_name from user_tables
6. Steps to create a tablespace:
Divided into four steps
Step 1: create temporary tablespaces /
Create temporary tablespace user_temp
Tempfile'D:\ oracle\ oradata\ Oracle9i\ user_temp.dbf'
Size 50m
Autoextend on
Next 50m maxsize 20480m
Extent management local
/ step 2: create a data tablespace /
Create tablespace user_data
Logging
Datafile'D:\ oracle\ oradata\ Oracle9i\ user_data.dbf'
Size 50m
Autoextend on
Next 50m maxsize 20480m
Extent management local
/ step 3: create a user and specify a tablespace /
Create user username identified by password
Default tablespace user_data
Temporary tablespace user_temp
/ step 4: grant permissions to the user /
Grant connect,resource,dba to username
7. Accumulation of multiple data files:
Store the tablespace as multiple data files, each no larger than 32GB (the exact value is 32768m)
The syntax is as follows: (if not enough, continue to add data files)
-- add data files to the tablespace
Create tablespace JC_DATA
Logging
Datafile'F:\ app\ oracle\ oradata\ orcl\ JC_DATA01.dbf'
Size 50m
Autoextend on
Next 50m maxsize 32767m
Extent management local
-- add data files to the tablespace
Alter tablespace JC_DATA
Add datafile'F:\ app\ oracle\ oradata\ orcl\ JC_DATA02.dbf' size 50m
Autoextend on next 50m maxsize 32767m
8. Query whether the tablespace in the current database is automatically extended:
Query all:
Select tablespace_name,file_name,autoextensible from dba_data_files
Query the specified tablespace:
Select tablespace_name,file_name,autoextensible from dba_data_files where tablespace_name='NCCW_DATA'
Turn on the automatic extension function syntax:
Alter database datafile 'corresponding data file path information' autoextend on
Turn off the automatic extension function syntax:
Alter database datafile 'corresponding data file path information' autoextend off
Transferred from:
Https://hewei0212.iteye.com/blog/1884123
Https://www.cnblogs.com/netsql/articles/1745978.html
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.