for ROM upgrade:
1. download last rom from cisco site.
2. copy rom file to switch bootflash:
3. turn on switch and enter control-C to go to rommon
4. enter rommon 1 >boot bootflash:cat4500-ios-promupgrade-122_31r_SGA7(or your rom)
5. switch will restarted after upgraide
6. run show version | i ROM
for IOS upgrade:
1. download last ios
2. copy ios to switch bootflash:
3. enter show running-config | i boot system
4. go to config mode
5. enter no boot system flash bootflash:cat4500-entservicesk9-mz.122-13.SG1.bin(your ios)
6. enter boot system flash bootflash:cat4500-entservicesk9-mz.122-54.SG.bin
7. save config and reboot switch
8. check ios version after reboot show version | i bootflash