Upgrade IOS, tftp-DHCP

Unanswered Question
Sep 2nd, 2008
User Badges:


I have 1500 new 2960 switches, and want to upgrade image.

Do it manually seems time consuming, so I looked at Ciscos website to do this with DHCP on bootup. It gets the IP, tftp and start to download the image, then it stops. I have tried to set the hex value but still got problems.



This is my config.


ip dhcp pool dhcp


bootfile c2960-lanbase-tar.122-44.SE2.tar


option 150 ip

interface Vlan1

ip address

no ip route-cache


ip http server

tftp-server flash:c2960-lanbase-tar.122-44.SE2.tar

tftp-server flash:config-boot.text

And this is my result:

00:01:17: %LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan1, changed state to up

00:01:28: AUTOINSTALL: Vlan1 is assigned

00:01:28: AUTOINSTALL: Obtain tftp server address (opt 150)

00:01:28: AUTOINSTALL: Obtain default router (opt 3)

Loading c2960-lanbase-tar.122-44.SE2.tar from (via Vlan1): !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

[OK - 9953280 bytes]



% Invalid input detected at '^' marker.

00:02:56: %PARSER-4-BADCFG: Unexpected end of configuration file.

00:02:56: %SYS-5-CONFIG_I: Configured from tftp:// by console

It looks like it downloads the image from tftp, but then it says invalid input.

Is there someone who has done this.



  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 0 (0 ratings)
Giuseppe Larosa Tue, 09/02/2008 - 11:34
User Badges:
  • Super Silver, 17500 points or more
  • Hall of Fame,

    Founding Member

Hello Lamin,

I've never done this, however from the message above I think the client switch has taken the tar file for the config file.

the example in your reference is different:

Switch# config terminal

Switch(config)# ip dhcp pool pool1

Switch(dhcp-config)# network

Switch(dhcp-config)# bootfile config-boot.text

Switch(dhcp-config)# default-router

Switch(dhcp-config)# option 150

Switch(dhcp-config)# option 125 hex


Switch(dhcp-config)# exit

So first the client switch has to load a config file and later it will download the image.


Before following the steps in this table, you must create a text file (for example, autoinstall_dhcp) that will be uploaded to the switch. In the text file, put the name of the image that you want to download (for example, c37502970-ipservices-mz.122-44.3.SE.tar). This image must be a tar and not a bin file.

then the client switch can do:

This example uses a Layer 3 SVI interface on VLAN 99 to enable DHCP-based autoconfiguration with a saved configuration:

Switch# configure terminal

Switch(conf)# boot host dhcp

Switch(conf)# boot host retry timeout 300

Switch(conf)# banner config-save ^C Caution - Saving Configuration File to NVRAM May Cause

You to Nolonger Automatically Download Configuration Files at Reboot^C

Switch(config)# vlan 99

Switch(config-vlan)# interface vlan 99

Switch(config-if)# no shutdown

Switch(config-if)# end

Hope to help


lamin.sonko Thu, 09/11/2008 - 05:44
User Badges:


I found out from TAC that this is not supported on my IOS version 122-35.SE5


"- I want to tell you that dhcp auto image upgrade is available in 12.2(44) onwards"




This Discussion