I'm not sure if this is the place to ask this question but I have a script on an IBM RS6000 that has quit working. I can manually run a backup using SMIT and it appears okay, but not sure about the script.
"quit working" is not much to go on. Precisely what happens? I don't know AIX, but looking atthe backup man page, the only thing I notice is "/dev/rmt0.1" which looks odd. That man page says /dev/rmt0-1 would refer to two devices but I don't see any indication that a dot is acceptable. But since I don't know AIX, I suppose it might be legal.
The script is executed from the crontab or I can run it manually and I see no error as it runs, but when I run SMIT to view the contents of the tape backup I get the following error:
restore: 0511-160 Cannot read the backup media
/dev/rmt0: There is an input or output error.
The backups have been running for a couple of years and when I started randomly checking them after the network person left a month or so later I would get the error every so often until I was finally getting it every day. Not exactly sure where to go next.
I am not an expert, but I believe the ".1" after rmt0 tells the system not to rewind the tape so that another backup can be placed on the tape or allows a second backup on the same tape without writing over the first one. We have a backup that is similar. Here it is:
find /law1/DB/PROD -print | backup -iqvf /dev/rmt0.1
find /law1/lawson/ccsprod -print | backup -iqvf /dev/rmt0
I'm glad I put in all those caveats about .1 possibly being legal in my first post!
Looking at RTM's link, I see that the .1 special file will not rewind upon close. So you would need to rewind the tape before looking at it. Maybe the OP didn't realize that. And maybe smit uses /dev/rmt0 which does rewinds the tape which produces the bahavior that seems correct to the OP.
There are a lot of maybe's in this post... And once again, I do not know AIX.