Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

SWVPD Problem on AIXv4.3.3

Status
Not open for further replies.

venky1

Programmer
Mar 10, 2003
6
US
I get the following error when I try to run the lslpp command with any switches allowed.
"lslpp: 0504-302 ODM error 5803 occurred trying to read SWVPD data." If I try lslpp -L all I get...
"A system error occurred while attempting to access the Software Vital Product Data. Use local problem reporting procedures."
It seems that I've somehow corrupted my SWVPD, is there any way I can fix it manually by running a command or something?
 
How did this happen? Was an installation interrupted/corrupted?

What does 'lppchk -v' return?

If the files are totally screwed then you might have to restore from your mksysb the following ODM SWVPD classes:
/etc/objrepos/lpp
/etc/objrepos/product
/etc/objrepos/inventory
/usr/lib/objrepos/lpp
/usr/lib/objrepos/product
/usr/lib/objrepos/inventory
/usr/share/lib/objrepos/lpp
/usr/share/lib/objrepos/product
/usr/share/lib/objrepos/inventory

Be warned that if you do this you will lose all information regarding any installs done since the last backup.
 
Hi,
lppchk -v returns...
"A system error occurred while attempting to access the Software Vital Product Data. Use local problem reporting procedures."
What I was actually doing is that I was trying to figure out which file on the hard disk SMIT uses to extract information about a given fileset when we run the command say lslpp -L <fileset>. It seems that somehow I've ended up corrupting a few files coz. of which I now get this error. Assuming that the class files are actually corrupt, how exactly do I restore them from mksysb. Could you plz. give me the set/sequence of commands to do so?
Thanks
 
To restore selected files from mksysb, assuming you are using rmt0 -

1) Move to root filesystem
cd /
2) Ensure tape is starting from beginning:
tctl -f /dev/rmt0 rewind
3) Skip tape forward past the boot sectors:
tctl -f /dev/rmt0.1 fsf 3
4) Restore selected file (remember that relative path names are used):
restore -xvpf /dev/rmt0.1 ./etc/objrepos/lpp
5) Repeat steps 1-4 for all files you want to restore.


 
hi,

One simple thinh to check , probably a long shot ,is your
ODMDIR variable set to:-

ODMDIR=/etc/objrepos
 
Thanks for the steps, but I don't have any tape devices attached to my system. Is there any other way? Can I take backups to local files and then restore them from there? If so how do I go about doing that?

PS: DSMARWAY
Yes echo $ODMDIR returns /etc/objrepos.
 
venky1 - It's too late now to be taking backups of the ODM, I'm referring to backups that were made before you started making changes.

Were any such backups made and what was the method used?

If no such backups exist then you will have to backup whatever you want to keep from the current setup (data files, scripts etc) rebuild the O/S from scratch (reinstall) and then restore your backups, or attempt to fix the corruption.

Can you tell us what actually was being done to cause this corruption?

Can you still reference the ODM classes directly, example:
odmget -q 'name=bos.net.tcp.client' lpp
odmget -q 'lpp_name=bos.net.tcp.client' product
odmget -q 'lpp_id=74' inventory
 
Hi sectorseveng,
Yup, I understand it's too late now for the backups :) and unfortunately no backups were taken during initial install of the OS. Hmmm, no other option left but to install the entire OS from scratch huh. Well I guess I'll have to do that now.
Well the exact cause of corruption is that, I needed to find out whether say a particular s/w is installed. Now SMIT obviously shows that s/w in the list of installed softwares (which I thought it picked up from some flat file somewhere), so while trying to figure that out I was basically fiddling with some files in the ODM directories after taking copies of the originals. But when I did restore the originals I started getting this problem.
Of the 3 commands you've mentioned, the first 2 work fine and the third doesn't show any output at all.
Guess I'm off to taking backups and rebuilding my machine from scratch.
Thanks for you help, let me know incase you come across an easier way out. Have a good one.
 
venky1 - Sorry, the example I gave was not detailed enough.

Get the details from the lpp class:
odmget -q 'name=bos.net.tcp.client' lpp

Use the lpp_id which is shown from querying the lpp class when querying the inventory class:
eg, on my 4.3.3 systems:
odmget -q 'lpp_id=74' inventory
on my 5.1.0 systems:
odmget -q 'lpp_id=271' inventory

If this does not return data then it's the inventory that is corrupt. If you have another RS/6000 at the same oslevel then you could query its inventory and use the results to repair the first.

One other file might be the history class (which I forgot to put on the earlier list), use the same query you used for testing the inventory class to test this, eg:
odmget -q 'lpp_id=74' history

If both the inventory and history queries returns data OK then I'd guess the corruption is in the .vc (variable character) files, I know of no way to repair these.

Can you say which files you changed and which files you restored?
 
sectorseveng: the lpp_id for bos.net.tcp.client works out to 77 and using this in
odmget -q 'lpp_id=77' inventory or
odmget -q 'lpp_id=77' history returns valid data. Guess as suggested by you it seems that the .vc files are corrupt. As far as the files are concerned, it was typically files under /usr/share/lib/objrepos, /etc/objrepos
/usr/lib/objrepos.
Well I'm in kind of a fix now...I was trying to restore files from another RS6000(similarly configured, same OS level etc.) which meant copying files from one machines /usr/share/lib/objrepos to other
/etc/objrepos to other
/usr/lib/objrepos to other and so on. While doing so I was renaming the folders on the destination machine. In the middle of this process I had to reboot the machine. It now wouldn't come up as /etc/objrepos has been currently renamed as /etc/objrepos1 and it hangs at &quot;Starting software...Please wait&quot;. Dumb me !! :(.
I'm not able to telnet into it and change the directory name back. Also, how do I no boot of an AIX OS CD (guess that's the option left now)? I tried inserting disk1 of the OS CDs and rebooting but it doesn't work.
 
venky1 - It looks like the CD is not in your normal bootlist, so you will have to boot in service mode.
If this is an MCA box turn the key to service (the spanner) and reboot.
If this is a PCI box then reboot and hit 5 if using an ascii tyerminal or F5 if using a graphics terminal.
See the IBM techtips site (or the service manuals that came with the system) for further details on service booting:

BTW, the ODM files are not just flat files which you can edit/copy as you please. I mentioned querying the files on one system and using the results to rebuild another, not just copying them around. You should only ever try accessing/changing these files using the commands odmadd, odmchange, odmcreate, odmdrop, odmdelete, odmget & odmshow.

I really think you are going to have to read some manuals or get some training before you take any more actions.
 
sectorseveng:Yes I do agree with you that I should've not been directly playing with those odm files. Thanks for the inputs regarding the '5' key/F5 key combination for booting into service mode. The catch here is that hitting the F5 key during bootup of my 43P Model 150 RS/6000 gets me into a diagnostics menu with 5 options.
1. Diagnostic Routines
2. Advanced Diagnostic Routines
3. Task Selection
4. Resource Selection
5. Single User Mode
But choosing any of these options, leads to the machine &quot;to continue with the boot process&quot; and then it goes back to a hang. How do I get into the bootlist and force it to boot off my CDROM?
 
If there is a CD in the drive and it's not booting from it then you can try the custom bootlist (F6 during reboot), if this does not work then you'll have to go into SMS to view/change the custom bootlist.

To enter SMS reboot your system and press F1 during bootup (after the keyborad icon appears on screen).

Click on the multi-boot icon, then click on boot-sequence icon (and define the bootlist you want) or the install-from icon.

This information is in the manuals for your system in the service guide and users guide - read them. If you haven't got the dead tree version then you can download them as pdf files from:

Once you get the thing booted from CD then:
1) access rootvg without mounting filesystems.
2) mount /dev/hd4/mnt
3) cp -p /mnt/etc/objrepos1 /mnt/etc/objrepos
3) lslv -m hd5 # to find out which hdisk(s) have the boot sector
4) savebase -d /dev/hdisk0 # I'm using hdisk0 as an example, use the device that step 3 found.
5) remove CD
6) reboot.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top