mysql_multi启动数据库

1.初始化数据库

在$mysql_base目录下,新增加存放data的文件夹,用mysql_install_db命令执行初始化

[[email protected] scripts]# ./mysql_install_db --help | less
Usage: ./mysql_install_db [OPTIONS]
  --basedir=path       The path to the MySQL installation directory.
  --builddir=path      If using --srcdir with out-of-directory builds, you
                       will need to set this to the location of the build
                       directory where built files reside.
  --cross-bootstrap    For internal use.  Used when building the MySQL system
                       tables on a different host than the target.
  --datadir=path       The path to the MySQL data directory.
  --defaults-extra-file=name
                       Read this file after the global files are read.
  --defaults-file=name Only read default options from the given file name.
  --force              Causes mysql_install_db to run even if DNS does not
                       work.  In that case, grant table entries that normally
                       use hostnames will use IP addresses.
  --help               Display this help and exit.
  --ldata=path         The path to the MySQL data directory. Same as --datadir.
  --no-defaults        Don‘t read default options from any option file.
  --rpm                For internal use.  This option is used by RPM files
                       during the MySQL installation process.
  --skip-name-resolve  Use IP addresses rather than hostnames when creating
                       grant table entries.  This option can be useful if
                       your DNS does not work.
  --srcdir=path        The path to the MySQL source directory.  This option
                       uses the compiled binaries and support files within the
                       source tree, useful for if you don‘t want to install
                       MySQL yet and just want to create the system tables.
  --user=user_name     The login username to use for running mysqld.  Files
                       and directories created by mysqld will be owned by this
                       user.  You must be root to use this option.  By default
                       mysqld runs using your current login name and files and
                       directories that it creates will be owned by you.

All other options are passed to the mysqld program
[[email protected] scripts]# ./mysql_install_db --basedir=/usr/local/mysql --datadir=/usr/local/mysql/data2 --user=mysql
Installing MySQL system tables...
OK
Filling help tables...
OK

To start mysqld at boot time you have to copy
support-files/mysql.server to the right place for your system

PLEASE REMEMBER TO SET A PASSWORD FOR THE MySQL root USER !
To do so, start the server, then issue the following commands:

/usr/local/mysql/bin/mysqladmin -u root password ‘new-password‘
/usr/local/mysql/bin/mysqladmin -u root -h ora11g password ‘new-password‘

Alternatively you can run:
/usr/local/mysql/bin/mysql_secure_installation

which will also give you the option of removing the test
databases and anonymous user created by default.  This is
strongly recommended for production servers.

See the manual for more instructions.

You can start the MySQL daemon with:
cd /usr/local/mysql ; /usr/local/mysql/bin/mysqld_safe &

You can test the MySQL daemon with mysql-test-run.pl
cd /usr/local/mysql/mysql-test ; perl mysql-test-run.pl

Please report any problems at http://bugs.mysql.com/

[[email protected] scripts]# 

同样,再初始化一个data3

修改my.cnf的配置,添加上multi的相关属性,如果不是很清楚需要添加什么的话,可以参考mult给的例子

[[email protected] ~]# mysqld_multi --example

[mysqld_multi]
mysqld     = /usr/local/mysql/bin/mysqld_safe
mysqladmin = /usr/local/mysql/bin/mysqladmin
user       = multi_admin
password   = my_password

[mysqld2]
socket     = /tmp/mysql.sock2
port       = 3307
pid-file   = /usr/local/mysql/mysqldata2/hostname.pid2
datadir    = /usr/local/mysql/mysqldata2
language   = /usr/local/mysql/share/mysql/english
user       = unix_user1

[mysqld3]
mysqld     = /path/to/mysqld_safe
ledir      = /path/to/mysqld-binary/
mysqladmin = /path/to/mysqladmin
socket     = /tmp/mysql.sock3
port       = 3308
pid-file   = /usr/local/mysql/mysqldata3/hostname.pid3
datadir    = /usr/local/mysql/mysqldata3
language   = /usr/local/mysql/share/mysql/swedish
user       = unix_user2

[mysqld4]
socket     = /tmp/mysql.sock4
port       = 3309
pid-file   = /usr/local/mysql/mysqldata4/hostname.pid4
datadir    = /usr/local/mysql/mysqldata4
language   = /usr/local/mysql/share/mysql/estonia
user       = unix_user3

[mysqld6]
socket     = /tmp/mysql.sock6
port       = 3311
pid-file   = /usr/local/mysql/mysqldata6/hostname.pid6
datadir    = /usr/local/mysql/mysqldata6
language   = /usr/local/mysql/share/mysql/japanese
user       = unix_user4
[[email protected] ~]# 

我的相关配置如下:

[mysqld_multi]
mysqld     = /usr/local/mysql/bin/mysqld_safe
mysqladmin = /usr/local/mysql/bin/mysqladmin
user       = test
password   = test

# The MySQL server
[mysqld3306]
port            = 3306
socket          = /tmp/mysql3306.sock
pid-file        = /tmp/mysql3306.pid
skip-external-locking
key_buffer_size = 16K
max_allowed_packet = 1M
table_open_cache = 4
sort_buffer_size = 64K
read_buffer_size = 256K
read_rnd_buffer_size = 256K
net_buffer_length = 2K
thread_stack = 128K
basedir = /usr/local/mysql
datadir = /usr/local/mysql/data
server-id       = 1

[mysqld3307]
port            = 3307
socket          = /tmp/mysql3307.sock
pid-file        = /tmp/mysql3307.pid
skip-external-locking
key_buffer_size = 16K
max_allowed_packet = 1M
table_open_cache = 4
sort_buffer_size = 64K
read_buffer_size = 256K
read_rnd_buffer_size = 256K
net_buffer_length = 2K
thread_stack = 128K
basedir = /usr/local/mysql
datadir = /usr/local/mysql/data2
server-id       = 1

[mysqld3308]
port            = 3308
socket          = /tmp/mysql3308.sock
pid-file        = /tmp/mysql3308.pid
skip-external-locking
key_buffer_size = 16K
max_allowed_packet = 1M
table_open_cache = 4
sort_buffer_size = 64K
read_buffer_size = 256K
read_rnd_buffer_size = 256K
net_buffer_length = 2K
thread_stack = 128K
basedir = /usr/local/mysql
datadir = /usr/local/mysql/data3
server-id       = 1

主要需要注意的几个参数是:[mysqld_multi],port,socket,pid-file和datadir。

配置好之后,就可以启动了。

[[email protected] bin]# ./mysqld_multi --defaults-file=../my.cnf start 3306
[[email protected] bin]# ps -ef | grep mysq;
root     10384     1  1 13:21 pts/2    00:00:00 /bin/sh /usr/local/mysql/bin/mysqld_safe --port=3306 --socket=/tmp/mysql3306.sock --pid-file=/tmp/mysql3306.pid --skip-external-locking --key_buffer_size=16K --max_allowed_packet=1M --table_open_cache=4 --sort_buffer_size=64K --read_buffer_size=256K --read_rnd_buffer_size=256K --net_buffer_length=2K --thread_stack=128K --basedir=/usr/local/mysql --datadir=/usr/local/mysql/data --server-id=1
mysql    10665 10384  4 13:21 pts/2    00:00:00 /usr/local/mysql/bin/mysqld --basedir=/usr/local/mysql --datadir=/usr/local/mysql/data --plugin-dir=/usr/local/mysql/lib/plugin --user=mysql --skip-external-locking --key-buffer-size=16K --max-allowed-packet=1M --table-open-cache=4 --sort-buffer-size=64K --read-buffer-size=256K --read-rnd-buffer-size=256K --net-buffer-length=2K --thread-stack=128K --server-id=1 --log-error=/usr/local/mysql/data/ora11g.err --pid-file=/tmp/mysql3306.pid --socket=/tmp/mysql3306.sock --port=3306
root     10684  7661  0 13:21 pts/2    00:00:00 grep mysq
[[email protected] bin]# ps -ef | grep mysql
root     10384     1  0 13:21 pts/2    00:00:00 /bin/sh /usr/local/mysql/bin/mysqld_safe --port=3306 --socket=/tmp/mysql3306.sock --pid-file=/tmp/mysql3306.pid --skip-external-locking --key_buffer_size=16K --max_allowed_packet=1M --table_open_cache=4 --sort_buffer_size=64K --read_buffer_size=256K --read_rnd_buffer_size=256K --net_buffer_length=2K --thread_stack=128K --basedir=/usr/local/mysql --datadir=/usr/local/mysql/data --server-id=1
mysql    10665 10384  2 13:21 pts/2    00:00:00 /usr/local/mysql/bin/mysqld --basedir=/usr/local/mysql --datadir=/usr/local/mysql/data --plugin-dir=/usr/local/mysql/lib/plugin --user=mysql --skip-external-locking --key-buffer-size=16K --max-allowed-packet=1M --table-open-cache=4 --sort-buffer-size=64K --read-buffer-size=256K --read-rnd-buffer-size=256K --net-buffer-length=2K --thread-stack=128K --server-id=1 --log-error=/usr/local/mysql/data/ora11g.err --pid-file=/tmp/mysql3306.pid --socket=/tmp/mysql3306.sock --port=3306
root     10686  7661  0 13:21 pts/2    00:00:00 grep mysql
[[email protected] bin]# ./mysqld_multi --defaults-file=../my.cnf start 3307
[[email protected] bin]# ./mysqld_multi --defaults-file=../my.cnf start 3308
[[email protected] bin]# ps -ef | grep mysql
root     10384     1  0 13:21 pts/2    00:00:00 /bin/sh /usr/local/mysql/bin/mysqld_safe --port=3306 --socket=/tmp/mysql3306.sock --pid-file=/tmp/mysql3306.pid --skip-external-locking --key_buffer_size=16K --max_allowed_packet=1M --table_open_cache=4 --sort_buffer_size=64K --read_buffer_size=256K --read_rnd_buffer_size=256K --net_buffer_length=2K --thread_stack=128K --basedir=/usr/local/mysql --datadir=/usr/local/mysql/data --server-id=1
mysql    10665 10384  0 13:21 pts/2    00:00:00 /usr/local/mysql/bin/mysqld --basedir=/usr/local/mysql --datadir=/usr/local/mysql/data --plugin-dir=/usr/local/mysql/lib/plugin --user=mysql --skip-external-locking --key-buffer-size=16K --max-allowed-packet=1M --table-open-cache=4 --sort-buffer-size=64K --read-buffer-size=256K --read-rnd-buffer-size=256K --net-buffer-length=2K --thread-stack=128K --server-id=1 --log-error=/usr/local/mysql/data/ora11g.err --pid-file=/tmp/mysql3306.pid --socket=/tmp/mysql3306.sock --port=3306
root     10695     1  1 13:21 pts/2    00:00:00 /bin/sh /usr/local/mysql/bin/mysqld_safe --port=3307 --socket=/tmp/mysql3307.sock --pid-file=/tmp/mysql3307.pid --skip-external-locking --key_buffer_size=16K --max_allowed_packet=1M --table_open_cache=4 --sort_buffer_size=64K --read_buffer_size=256K --read_rnd_buffer_size=256K --net_buffer_length=2K --thread_stack=128K --basedir=/usr/local/mysql --datadir=/usr/local/mysql/data2 --server-id=1
mysql    10978 10695  7 13:21 pts/2    00:00:00 /usr/local/mysql/bin/mysqld --basedir=/usr/local/mysql --datadir=/usr/local/mysql/data2 --plugin-dir=/usr/local/mysql/lib/plugin --user=mysql --skip-external-locking --key-buffer-size=16K --max-allowed-packet=1M --table-open-cache=4 --sort-buffer-size=64K --read-buffer-size=256K --read-rnd-buffer-size=256K --net-buffer-length=2K --thread-stack=128K --server-id=1 --log-error=/usr/local/mysql/data2/ora11g.err --pid-file=/tmp/mysql3307.pid --socket=/tmp/mysql3307.sock --port=3307
root     11003     1  1 13:21 pts/2    00:00:00 /bin/sh /usr/local/mysql/bin/mysqld_safe --port=3308 --socket=/tmp/mysql3308.sock --pid-file=/tmp/mysql3308.pid --skip-external-locking --key_buffer_size=16K --max_allowed_packet=1M --table_open_cache=4 --sort_buffer_size=64K --read_buffer_size=256K --read_rnd_buffer_size=256K --net_buffer_length=2K --thread_stack=128K --basedir=/usr/local/mysql --datadir=/usr/local/mysql/data3 --server-id=1
mysql    11286 11003 15 13:21 pts/2    00:00:00 /usr/local/mysql/bin/mysqld --basedir=/usr/local/mysql --datadir=/usr/local/mysql/data3 --plugin-dir=/usr/local/mysql/lib/plugin --user=mysql --skip-external-locking --key-buffer-size=16K --max-allowed-packet=1M --table-open-cache=4 --sort-buffer-size=64K --read-buffer-size=256K --read-rnd-buffer-size=256K --net-buffer-length=2K --thread-stack=128K --server-id=1 --log-error=/usr/local/mysql/data3/ora11g.err --pid-file=/tmp/mysql3308.pid --socket=/tmp/mysql3308.sock --port=3308
root     11305  7661  0 13:21 pts/2    00:00:00 grep mysql
[[email protected] bin]# 

中间有一个小插曲,因为我在安装mysql的时候,cmake . -DCMAKE_INSTALL_PREFIX=/usr/local/mysql -DMYSQL_DATADIR=/usr/local/mysql/data -DSYSCONFDIR=/etc\ ,当时制定的DMYSQL_DATADIR为mysqldata,所以在启动的时候,会报错:

[[email protected] share]# more mysqld_multi.log
mysqld_multi log file version 2.16; run: Fri Mar 28 12:58:30 2014

Starting MySQL servers

140328 12:58:30 [Warning] Can‘t create test file /usr/local/mysql/mysqldata/ora11g.lower-test
140328 12:58:30 [Warning] Can‘t create test file /usr/local/mysql/mysqldata/ora11g.lower-test
/usr/local/mysql/bin/mysqld: Can‘t change dir to ‘/usr/local/mysql/mysqldata/‘ (Errcode: 2)
140328 12:58:30 [ERROR] Aborting

140328 12:58:30 [Note] /usr/local/mysql/bin/mysqld: Shutdown complete

mysqld_multi log file version 2.16; run: Fri Mar 28 12:59:07 2014

Starting MySQL servers

140328 12:59:07 [Warning] Can‘t create test file /usr/local/mysql/mysqldata/ora11g.lower-test
140328 12:59:07 [Warning] Can‘t create test file /usr/local/mysql/mysqldata/ora11g.lower-test
/usr/local/mysql/bin/mysqld: Can‘t change dir to ‘/usr/local/mysql/mysqldata/‘ (Errcode: 2)
140328 12:59:07 [ERROR] Aborting

只需要把mysql_safe里面相应的data的目录从mysqldata改为data就可以正常启动了。

# Next try where the source installs put it
elif test -d $MY_BASEDIR_VERSION/var/mysql
then
  DATADIR=$MY_BASEDIR_VERSION/var
# Or just give up and use our compiled-in default
else
  DATADIR=/usr/local/mysql/data
fi

再进数据库查看:

[[email protected] bin]# cd /tmp
[[email protected] tmp]# ls
keyring-HcV70B  mysql3306.pid   mysql3307.pid   mysql3308.pid   scim-panel-socket:0-root  vmware-root
mapping-root    mysql3306.sock  mysql3307.sock  mysql3308.sock  ssh-WENobU7545
[[email protected] tmp]# ll
total 24
drwx------ 2 root  root  4096 Sep 26  2013 keyring-HcV70B
srwxr-xr-x 1 root  root     0 Sep 26  2013 mapping-root
-rw-rw---- 1 mysql mysql    6 Mar 28 13:21 mysql3306.pid
srwxrwxrwx 1 mysql mysql    0 Mar 28 13:21 mysql3306.sock
-rw-rw---- 1 mysql mysql    6 Mar 28 13:21 mysql3307.pid
srwxrwxrwx 1 mysql mysql    0 Mar 28 13:21 mysql3307.sock
-rw-rw---- 1 mysql mysql    6 Mar 28 13:21 mysql3308.pid
srwxrwxrwx 1 mysql mysql    0 Mar 28 13:21 mysql3308.sock
srw------- 1 root  root     0 Nov 15  2012 scim-panel-socket:0-root
drwx------ 2 root  root  4096 Mar 28 09:57 ssh-WENobU7545
drwx------ 2 root  root  4096 Mar 27 17:03 vmware-root
[[email protected] tmp]# mysql -S mysql3306.sock
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 1
Server version: 5.5.37 Source distribution

Copyright (c) 2000, 2014, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type ‘help;‘ or ‘\h‘ for help. Type ‘\c‘ to clear the current input statement.

mysql> show databases;
+--------------------+
| Database           |
+--------------------+
| information_schema |
| mysql              |
| performance_schema |
| test               |
+--------------------+
4 rows in set (0.00 sec)

mysql> exit
Bye
[[email protected] tmp]# mysql -S mysql3308.sock
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 1
Server version: 5.5.37 Source distribution

Copyright (c) 2000, 2014, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type ‘help;‘ or ‘\h‘ for help. Type ‘\c‘ to clear the current input statement.

mysql> show databases;
+--------------------+
| Database           |
+--------------------+
| information_schema |
| mysql              |
| performance_schema |
| test               |
+--------------------+
4 rows in set (0.00 sec)

mysql> exit
Bye
[[email protected] tmp]# 

当想使用stop来关闭的时候:

[[email protected] mysql]# mysqld_multi --defaults-file=my.cnf stop 3306

发现log里面报错:

mysqld_multi log file version 2.16; run: Fri Mar 28 13:42:17 2014

Stopping MySQL servers

/usr/local/mysql/bin/mysqladmin: connect to server at ‘localhost‘ failed
error: ‘Access denied for user ‘test‘@‘localhost‘ (using password: YES)‘

原来是相应的数据库里面还没有这个用户以及相应的权限。

去数据库中创建用户并授权:

[[email protected] tmp]# ls -lrt
total 24
srw------- 1 root  root     0 Nov 15  2012 scim-panel-socket:0-root
drwx------ 2 root  root  4096 Sep 26  2013 keyring-HcV70B
srwxr-xr-x 1 root  root     0 Sep 26  2013 mapping-root
drwx------ 2 root  root  4096 Mar 27 17:03 vmware-root
drwx------ 2 root  root  4096 Mar 28 09:57 ssh-WENobU7545
srwxrwxrwx 1 mysql mysql    0 Mar 28 13:21 mysql3306.sock
-rw-rw---- 1 mysql mysql    6 Mar 28 13:21 mysql3306.pid
srwxrwxrwx 1 mysql mysql    0 Mar 28 13:21 mysql3307.sock
-rw-rw---- 1 mysql mysql    6 Mar 28 13:21 mysql3307.pid
srwxrwxrwx 1 mysql mysql    0 Mar 28 13:21 mysql3308.sock
-rw-rw---- 1 mysql mysql    6 Mar 28 13:21 mysql3308.pid
[[email protected] tmp]# mysql -S mysql3306.sock
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 3
Server version: 5.5.37 Source distribution

Copyright (c) 2000, 2014, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type ‘help;‘ or ‘\h‘ for help. Type ‘\c‘ to clear the current input statement.

mysql> grant shutdown on *.* to [email protected] identified by ‘test‘ with grant option;
Query OK, 0 rows affected (0.00 sec)

mysql> show grants for [email protected];
+---------------------------------------------------------------+
| Grants for [email protected]                                     |
+---------------------------------------------------------------+
| GRANT SHUTDOWN ON *.* TO ‘test‘@‘localhost‘ WITH GRANT OPTION |
+---------------------------------------------------------------+
1 row in set (0.01 sec)

mysql> 

创建完毕后,再去停数据库:

[[email protected] mysql]# mysqld_multi --defaults-file=my.cnf stop 3306-3308
[[email protected] mysql]# ps -ef | grep 3306
root 11551 7661 0 13:49 pts/2 00:00:00 mysql -S mysql3306.sock
root 11583 7547 0 13:51 pts/1 00:00:00 grep 3306

可以在日志中发现已经能正常的进行关闭了。
Stopping MySQL servers

140328 13:50:53 mysqld_safe mysqld from pid file /tmp/mysql3306.pid ended

相应的,在tmp目录下面的socket文件也会相应的删除了。

140328 13:50:55 mysqld_safe mysqld from pid file /tmp/mysql3307.pid ended
mysqld_multi log file version 2.16; run: Fri Mar 28 13:50:56 2014

Stopping MySQL servers

140328 13:50:57 mysqld_safe mysqld from pid file /tmp/mysql3308.pid ended

mysql_multi启动数据库,布布扣,bubuko.com

时间: 2024-10-18 11:09:40

mysql_multi启动数据库的相关文章

linux下oracle如何启动数据库

首先使用oracle用户登录Linux,然后在shell命令行中执行下面的命令:第一步:打开Oracle监听$ lsnrctl start第二步:进入sqlplus$ sqlplus /nologSQL>第三步:使用sysdab角色登录sqlplusSQL> conn /as sysdba第四步:启动数据库SQL> startup经过上面的四个步骤,oracle数据库就可以启动了.

Oracle12c启动数据库报错:ORA-01078: failure in processing system parameters

单实例oracle12102安装完成后,startup报错: [[email protected] ~]$ sqlplus "/as sysdba" SQL*Plus: Release 12.1.0.2.0 Production on Sat Sep 16 15:04:46 2017 Copyright (c) 1982, 2014, Oracle.  All rights reserved. Connected to an idle instance. SQL> startup

sqlserver如何启动数据库邮件

1 可以在 msdb 数据库中停止数据库邮件.若要检查数据库邮件的状态,请执行下面的语句: 2 3 4 5 6 7 8 复制 9 10 11 EXECUTE dbo.sysmail_help_status_sp; 12 13 14 若要在邮件主机数据库中启动数据库邮件,请在 msdb 数据库中运行以下命令: 15 16 17 18 19 20 21 复制 22 23 24 EXECUTE dbo.sysmail_start_sp;

如何手工启动数据库自动归档模式

如果在Oracle安装时没有开启自动归档的模式的话,需要手工启动归档模式. a)        修改log_archive_start定义是否自动归档,10g版本后,这个参数作废,即使值是FALSE也自动归档,当前系统是11g,所以无需更改. b)        可以修改log_archive_format定义归档文件格式,一般使用默认值即可. c)        修改log_archive_dest_1,设置归档文件的目标目录. alter system set log_archive_des

启动数据库并登录数据库

1.切换到对应的目录下 cd E:\MySQL\mysql-5.7.16-winx64\bin //mysql安装在此目录下 2.首次安装需要经历的步骤 mysqld install mysqld --initialize --console //初始化数据库,初始化后data文件夹会自动生成 mysqld --initialize ,这一步用于初始化data目录,官方的压缩包解压后并没有data文件夹,运行命令后,自动在根目录下生成data文件夹. 3.输入命令,//启动服务: net sta

因信号量问题导致ORA-27154无法启动数据库

测试库执行startup时提示(11.2.0.1): 查询ORA-27154的错误: Error: ORA-27154 Text: post/wait create failed --------------------------------------------------------------------------- Cause: internal error, multiple post/wait creates attempted simultaneously Action: c

关于Django无法启动数据库和无法命令行启动manage.py的解决方法

问题介绍: 本人在两天内也无法解决Django中遇到的一些问题,我学习是看视频学习的,视频中并没有讲解一些东西,我在同步数据库时,无法命令启动.manage.py文件无法启动,命令行报错为无法导入Django,后面不知道自己如何修改了一下,浏览器报的错误为操作错误: OperationalError at /userInfo/ no such table: bolg_userinfo Request Method: POST Request URL: http://127.0.0.1:8000/

Mariadb 修改root密码及跳过授权方式启动数据库

默认情况下,yum方式新安装的 mariadb 的密码为空,在shell终端直接输入 mysql 就能登陆数据库. 如果是刚安装第一次使用,请使用 mysql_secure_installation 命令初始化. # mysql_secure_installation NOTE: RUNNING ALL PARTS OF THIS SCRIPT IS RECOMMENDED FOR ALL MariaDB SERVERS IN PRODUCTION USE! PLEASE READ EACH S

手动启动数据库归档

-查看实例进程看是否有归档的进程 [[email protected] ~]$ ps -ef | grep PROD4 SQL> archive log list; Database log mode       No Archive Mode Automatic archival       Disabled Archive destination      /u01/app/oracle/product/11.2.0/db_1/dbs/archOldest online log sequen