Sudoers file and system shutdown problem - HP UX

This is a discussion on Sudoers file and system shutdown problem - HP UX ; Help please I have today messed up my sudoers file which means no users can sudo in to our system. I therefore need to do a restore of the file - no problems, I have a backup. Now comes the ...

+ Reply to Thread
Results 1 to 5 of 5

Thread: Sudoers file and system shutdown problem

  1. Sudoers file and system shutdown problem

    Help please

    I have today messed up my sudoers file which means no users can sudo in
    to our system.

    I therefore need to do a restore of the file - no problems, I have a
    backup.

    Now comes the problem.

    The system is secure, and nobody seems to know the root password.

    The system will not let me su - to log in as root

    How do I run the Shutdown process, as I need to log in as root to run
    this?

    Many thanks

    Gary


  2. Re: Sudoers file and system shutdown problem

    gary.cobden@nhs.net wrote:
    > The system is secure, and nobody seems to know the root password.
    > How do I run the Shutdown process, as I need to log in as root to run
    > this?


    Are you sure the single-user boot is unprotected?

    --
    Alex.

  3. Re: Sudoers file and system shutdown problem

    On 2005-09-30, gary.cobden@nhs.net wrote:

    > I have today messed up my sudoers file which means no users can sudo in
    > to our system.


    This is why right way to change the sudoers file is using visudo.
    (And batch changes should use "visudo -c" on the temp tile before renaming it.)


    > The system is secure, and nobody seems to know the root password.


    How do you know it's secure ?

    --
    Elvis Notargiacomo master AT barefaced DOT cheek
    http://www.notatla.org.uk/goen/
    Powergen write "Why not stay with us" - let me count the ways!

  4. Re: Sudoers file and system shutdown problem

    gary.cobden@nhs.net wrote:

    > Help please
    >
    > I have today messed up my sudoers file which means no users can sudo in
    > to our system.
    >
    > I therefore need to do a restore of the file - no problems, I have a
    > backup.
    >
    > Now comes the problem.
    >
    > The system is secure, and nobody seems to know the root password.
    >
    > The system will not let me su - to log in as root
    >
    > How do I run the Shutdown process, as I need to log in as root to run
    > this?
    >
    > Many thanks
    >
    > Gary
    >

    is there a /etc/shutdown.allow file on the system? if it has no names
    then only root can reboot, if there are other names then they can
    shutdown too. If the system is set in secure mode then you will need to
    power off the system, disconnect the primary and secondary boot disk
    then power it up, once it is done with self test it will fail boot and
    reset secure mode. Then power down again, reconnect disks and then
    interuppt the IPL and you can then go to single user mode and change
    root's passwd.

  5. Re: Sudoers file and system shutdown problem

    gary.cobden@nhs.net writes:

    > Help please
    >
    > I have today messed up my sudoers file which means no users can sudo in
    > to our system.
    >
    > I therefore need to do a restore of the file - no problems, I have a
    > backup.
    >
    > Now comes the problem.
    >
    > The system is secure, and nobody seems to know the root password.


    If you are using HP's Data Protector, you could restore /etc/passwd of any
    system to the target system without knowing the root password (for the
    restore). If you (temporarily) restore a password file where you know the
    root's password, you could log in. When in doubt, prepare an empty root
    password on some machine, backup, and restore it to the target machine. Log in
    as root, then restore the last good password file to the target and change the
    root's password. For the future maybe install an authorized SSH key for root
    login without knowing a password...

    Hope it helps.

    Regards,
    Ulrich

    >
    > The system will not let me su - to log in as root
    >
    > How do I run the Shutdown process, as I need to log in as root to run
    > this?
    >
    > Many thanks
    >
    > Gary


+ Reply to Thread