Обсуждение: Ubuntu: Start and Stop

Поиск
Список
Период
Сортировка

Ubuntu: Start and Stop

От
Sidar López Cruz
Дата:
How to start and stop automatically PostgreSQL over Ubuntu when  postgres
user have password.
I'd try with su - postgres but this fails because it request me the password

Please help....

_________________________________________________________________
Charla con tus amigos en línea mediante MSN Messenger:
http://messenger.latam.msn.com/


Re: Ubuntu: Start and Stop

От
"Joshua D. Drake"
Дата:
Sidar López Cruz wrote:
> How to start and stop automatically PostgreSQL over Ubuntu when
> postgres user have password.
> I'd try with su - postgres but this fails because it request me the
> password

You would be better served to use #ubuntu on chat.us.freenode.net.

However in answer to your question... use:

sudo su -

Which will ask you for your standard user password. Then:

/etc/init.d/postgresql (or /etc/init.d/postgresql8) stop/start

Sincerely,

Joshua D. Drake


>
> Please help....
>
> _________________________________________________________________
> Charla con tus amigos en línea mediante MSN Messenger:
> http://messenger.latam.msn.com/
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 9: In versions below 8.0, the planner will ignore your desire to
>       choose an index scan if your joining column's datatypes do not
>       match
>


--

             === The PostgreSQL Company: Command Prompt, Inc. ===
       Sales/Support: +1.503.667.4564 || 24x7/Emergency: +1.800.492.2240
       Providing the most comprehensive  PostgreSQL solutions since 1997
                      http://www.commandprompt.com/



Re: Ubuntu: Start and Stop

От
Tom Lane
Дата:
"Joshua D. Drake" <jd@commandprompt.com> writes:
> sudo su -
> /etc/init.d/postgresql (or /etc/init.d/postgresql8) stop/start

Or easier, just

    sudo /sbin/service postgresql stop/start

You will need to add your own userid to the sudoers list if it's
not already there.

            regards, tom lane

Re: Ubuntu: Start and Stop

От
"Joshua D. Drake"
Дата:
>
>     sudo /sbin/service postgresql stop/start
>
> You will need to add your own userid to the sudoers list if it's
> not already there.

Just for reference, Ubuntu automatically adds the first user created to
the sudoers file and actually disables the ability to "log in" as root.


Sincerely,

Joshua D. Drake

>
>             regards, tom lane
>


--

             === The PostgreSQL Company: Command Prompt, Inc. ===
       Sales/Support: +1.503.667.4564 || 24x7/Emergency: +1.800.492.2240
       Providing the most comprehensive  PostgreSQL solutions since 1997
                      http://www.commandprompt.com/