Error when trying to execute the child script with "nohup"

Jean-Marc Monnez monnez.jean-marc at agora.msa.fr
Thu Sep 12 08:08:36 EDT 2002


Same problem : no rights to create a file in directory.
You must give a filepath for the outfile in a directory where the user has rights, or give him these rights on
current dir.

-- JMM

Sorayuth.Kamthawee at orange.co.th wrote :

> Dear JMM,
>
> I have already tried that solution before but it's still has the problem
> with other error messege as following:
>
>      ./parent.sh: child.out: Cannot create the specified file.
>
> Regards,
>
> SKE.
>
>
>                     monnez.jean-marc at ag
>                     ora.msa.fr                To:     Sorayuth.Kamthawee at orange.co.th
>                                               cc:     sudo-users at sudo.ws, sudo-users-admin at sudo.ws
>                     12/09/2002 04:02 PM       Subject:     Re: Error when trying to execute the child script with
>                                                "nohup"
>
>
> If you don't redirect stdout and stderr, nohup needs to open a nohup.out
> file
> in current directory, with the rights of the owner of the process.
> Either you give the rights to the user to write in current dir, or better :
> nohup ./child.sh   >>child.out  2>&1  &
>
> Regards
>
> -- JMM
>
> Sorayuth.Kamthawee at orange.co.th wrote :
>
> > All,
> >
> > Please help me find the solutions, I have wrote the script (called
> PARENT)
> > that have to call other script (called CHILD) using "nohup" and out the
> > child script to background job as following:
> >
> > -------------------- Begin of PARENT script -----------------------
> > nohup ./child.sh &
> > -------------------- End of PARENT script -------------------------
> >
> > -------------------- Begin of CHILD script ------------------------
> > command_or_script_here
> > -------------------------------------------------------------------
> >
> > The error message will shown as, "nohup: cannot open/create nohup.out".
> But
> > this won't error if we run under the root account (like sudo -u root
> > .....).
> >
> > Hope someone ever found the problem like this.
> >
> > Thanks all,
> >
> > sam.
> >
> > ____________________________________________________________
> > sudo-users mailing list <sudo-users at sudo.ws>
> > For list information, options, or to unsubscribe, visit:
> > http://www.sudo.ws/mailman/listinfo/sudo-user
> (Embedded image moved to file: pic09857.pcx)
>
>   ------------------------------------------------------------------------
>                    Name: pic09857.pcx
>    pic09857.pcx    Type: Image Paintbrush (application/x-unknown-content-type-PBrush)
>                Encoding: base64




More information about the sudo-users mailing list