Re: Re: Can't execute star cronjob

Joerg Schilling <[email protected]>
Newsgroups gmane.comp.archivers.star.user
Message-ID <4341282C.nail8JN11AS69@burner>
[email protected] wrote:

> Hi,
>
> > Opcije="-fifostats -multivol -time"
> > BlockSize=8m
> > FifoSize=128m
> > TapeDev="/tmp/arhiva.star"
> > Log="/tmp/tblib-$BckStart.log"
> > star -c bs="$BlockSize" fs="$FifoSize" $Opcije -V pat=firmware/\* -V \
> > pat=security/\* f="$TapeDev" . 2>> "$Log"
> > 
> > So, my cronjob (only for this test purpose) will execute every minute.
> > Result is mail message with following in attachment:
> > star: No such device or address. Cannot open '/dev/tty'.
> > 
> > Why I am getting this "star: No such device or address. Cannot open 
> > '/dev/tty'." error?
>
> I fgrep'ed for "/dev/tty" in star-1.5/star/*.c and found
>
>         if (interactive || ask_remove ||
>             ((multivol || tsize > 0) && !newvol_script)) {
>         ...
>                 if ((tty = fileopen("/dev/tty", "r")) == (FILE *)NULL)
>                         comerr("Cannot open '/dev/tty'.\n");
>
> which leads me to the theory that your option "-multivol" is the
> reason why star prepares to ask you for an eventual second tape.
> If you really want to handle multivolume archives under cron
> then you will have to find a different solution. 

This is correct, you cannot use star from cron in a way that requires
manual intervention.

If you like to use "-multivol" in a non-interactice command, you would
need to automate this and this forces you to use the new-volume-script=script
option.

Jörg

-- 
 EMail:[email protected] (home) Jörg Schilling D-13353 Berlin
       [email protected]		(uni)  
       [email protected]	(work) Blog: http://schily.blogspot.com/
 URL:  http://cdrecord.berlios.de/old/private/ ftp://ftp.berlios.de/pub/schily
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.