Page 1 of 1

Stopping a database that has a pw

Posted: Wed Jan 28, 2015 3:40 am
by Julie
Hello,

I am getting an error when trying to use the stop_db tool per the admintools command line:

Code: Select all

[dbadmin@v01 ~]$ admintools -t stop_db -d my_test_db
Info: no password specified, using none
        Issuing shutdown command to database
Database my_test_db not stopped successfully
 Error: Invalid username or password
So I thought I could just use the -w option (i.e. password), but that doesn't work 'cause I get this error:

Code: Select all

[dbadmin@v01 ~]$ admintools -t stop_db -d my_test_db -w password
Usage: stop_db [options]

stop_db: error: no such option: -w
So how the heck do I pass in the password to admintools?

Re: Stopping a database that has a pw

Posted: Wed Jan 28, 2015 3:54 am
by JimKnicely
Hey Julie,

The -w option is for the password in vsql, while -p is used for admintools. You can get this info from the --help option:

Code: Select all

[dbadmin@alf01 ~]$ admintools -t stop_db --help
Usage: stop_db [options]

Options:
  -h, --help            show this help message and exit
  -d DB, --database=DB  Name of database to be stopped
  -p DBPASSWORD, --password=DBPASSWORD
                        Database password in single quotes
  -F, --force           Force the databases to shutdown, even if users are
                        connected.
  -i, --noprompts       do not stop and wait for user input(default false)

Re: Stopping a database that has a pw

Posted: Thu Jan 29, 2015 12:11 am
by Julie
Ahhhhhhhh! Darn, I should have known that! Thanks Jim!