VPS.NET Cloud Community: HOWTO: Upgrade Debian 5 (Lenny) to Debian 6 (Squeeze) on vps.net - VPS.NET Cloud Community

Jump to content

  • (2 Pages)
  • +
  • 1
  • 2
  • You cannot start a new topic
  • This topic is locked

HOWTO: Upgrade Debian 5 (Lenny) to Debian 6 (Squeeze) on vps.net Rate Topic: -----

#1 User is offline   anthonysomerset 

  • On Cloud 9
  • PipPipPip
  • Group: Customers
  • Posts: 618
  • Joined: 16-September 09
  • LocationLondon, UK

Posted 21 February 2011 - 05:32 PM

Here are the Working upgrade instructions from Lenny to Squeeze (Debian 6)

Disclaimer: test this yourself first, this has only been tested on a default lenny install, i have yet to test with the ksplice mods (should be ok though) - Update ksplice seems to work fine with this.

fully update your lenny system (recommended to avoid some gpg errors)
apt-get update && apt-get upgrade


i recommend rebooting here just as a safety measure

reboot


reconnect then:

change sources list
nano /etc/apt/sources.list


your sources list should look like this (for UK servers)

deb http://ftp.uk.debian.org/debian/ squeeze main
deb-src http://ftp.uk.debian.org/debian/ squeeze main

deb http://security.debian.org/ squeeze/updates main
deb-src http://security.debian.org/ squeeze/updates main

deb http://ftp.uk.debian.org/debian squeeze-updates main
deb-src http://ftp.uk.debian.org/debian squeeze-updates main


update package lists
apt-get update


install locales update (to stop lots of annoying errors while upgrading)
apt-get install locales


update the kernel and install udev first
apt-get update && apt-get install linux-image-`uname -r|sed 's,[^-]*-[^-]*-,,'` udev


when asked for change to UUID's - select NO

now edit your /boot/grub/menu.lst and edit any reference of sda1 to xvda1 (should be 3)
also edit your /etc/fstab file to edit any references to sdaN to xvdaN (generally just 2)

reboot again
reboot


check your kernel version
uname -r

should return something starting with 2.6.32 similar to:
2.6.32-5-xen-amd64


then the final upgrade
apt-get dist-upgrade


when you are asked for options

change to dash - doesnt matter which is chosen

chainload grub 2 - NO

change to dependancy based sequencing (i selected yes and its fine)

restart services just hit enter

reboot for good luck (isnt actually needed because kernel is already up to date but better to eliminate issues ahead of crunch time

reboot

This post has been edited by anthonysomerset: 07 June 2011 - 12:56 PM

4

#2 User is offline   SteveSRS 

  • I Got Nodes
  • PipPipPip
  • Group: Customers
  • Posts: 35
  • Joined: 15-September 09

Posted 28 March 2011 - 09:50 PM

Hi,

Thanks for the how-to. Forgive my ignorance but, what are the (possible) reasons for doing this update?
Faster? More secure? other?

Thanks
0

#3 User is offline   anthonysomerset 

  • On Cloud 9
  • PipPipPip
  • Group: Customers
  • Posts: 618
  • Joined: 16-September 09
  • LocationLondon, UK

Posted 30 March 2011 - 03:58 PM

for me it was updated php and nginx in the core debian repo's rather than having to use backports or external repo's like dotdeb

i still actually use dotdeb but its now an option to not use it :)

also its a newer kernel so likely has some security and performance updates and a lot of software is now using more up to date versions
0

#4 User is offline   SteveSRS 

  • I Got Nodes
  • PipPipPip
  • Group: Customers
  • Posts: 35
  • Joined: 15-September 09

Posted 31 March 2011 - 07:30 PM

ok thanks. I think I will keep it off for 1 or 2 months and then do upgrade to also directly update php to 5.3.
0

#5 User is offline   anthonysomerset 

  • On Cloud 9
  • PipPipPip
  • Group: Customers
  • Posts: 618
  • Joined: 16-September 09
  • LocationLondon, UK

Posted 31 March 2011 - 08:05 PM

just a note

the debian 6 templates provided by onapp/vps.net are actually buggy so i wouldnt recommend using those just yet either, the upgrade has been working smoothly for me as i gradually do it on client servers
0

#6 User is offline   akia 

  • I Got Nodes
  • PipPipPip
  • Group: Customers
  • Posts: 37
  • Joined: 01-April 10

Posted 03 June 2011 - 10:17 PM

How is it buggy?
0

#7 User is offline   anthonysomerset 

  • On Cloud 9
  • PipPipPip
  • Group: Customers
  • Posts: 618
  • Joined: 16-September 09
  • LocationLondon, UK

Posted 04 June 2011 - 03:02 PM

you cant upgrade the kernel on the debian 6 templates currently without it failing due to wrong grub bootloader setup

if you do apt-get will forever fail everytime even if it successfully installs what you want to install

this means doing things like trying to install ksplice to fail as the install script requires a success result from apt during its install
0

#8 User is offline   akia 

  • I Got Nodes
  • PipPipPip
  • Group: Customers
  • Posts: 37
  • Joined: 01-April 10

Posted 04 June 2011 - 04:25 PM

Ah thank you, that may explaine why I've been having a few problems with my server.
0

#9 User is offline   akia 

  • I Got Nodes
  • PipPipPip
  • Group: Customers
  • Posts: 37
  • Joined: 01-April 10

Posted 04 June 2011 - 09:11 PM

Does anyone know whether anyone from VPS.net has fixed the problem with the images yet or whether its possible to fix it myself?
0

#10 User is offline   anthonysomerset 

  • On Cloud 9
  • PipPipPip
  • Group: Customers
  • Posts: 618
  • Joined: 16-September 09
  • LocationLondon, UK

Posted 05 June 2011 - 02:11 PM

to my knowledge no despite being told a couple of times now its being worked on

in all honesty i think they should hide the images until that bug is fixed
0

#11 User is offline   Black 

  • I Got Nodes
  • Pip
  • Group: Customers
  • Posts: 7
  • Joined: 23-May 10

Posted 05 June 2011 - 05:43 PM

Hello. In step "update the kernel and install udev first" remove the "apt-get upgrade" part from the command
0

#12 User is offline   anthonysomerset 

  • On Cloud 9
  • PipPipPip
  • Group: Customers
  • Posts: 618
  • Joined: 16-September 09
  • LocationLondon, UK

Posted 06 June 2011 - 08:21 AM

Hi Black

is there any reason to do so as the steps above work perfectly?
0

#13 User is offline   Black 

  • I Got Nodes
  • Pip
  • Group: Customers
  • Posts: 7
  • Joined: 23-May 10

Posted 06 June 2011 - 10:53 AM

View Postanthonysomerset, on 06 June 2011 - 08:21 AM, said:

Hi Black

is there any reason to do so as the steps above work perfectly?


Well. apt-get upgrade wont only upgrade kernel and udev but all the packages which wont pull any extra deps. Its almost like doing a full dist-upgrade. You cant really know how many packages a user has installed in the first place. It works for almost all basic installions, but how can you be sure about other builds?
0

#14 User is offline   anthonysomerset 

  • On Cloud 9
  • PipPipPip
  • Group: Customers
  • Posts: 618
  • Joined: 16-September 09
  • LocationLondon, UK

Posted 07 June 2011 - 06:57 AM

View PostBlack, on 06 June 2011 - 10:53 AM, said:


Well. apt-get upgrade wont only upgrade kernel and udev but all the packages which wont pull any extra deps. Its almost like doing a full dist-upgrade. You cant really know how many packages a user has installed in the first place. It works for almost all basic installions, but how can you be sure about other builds?


good point thanks for the comments, can you verify that it still works without that extra command in?
0

#15 User is offline   Black 

  • I Got Nodes
  • Pip
  • Group: Customers
  • Posts: 7
  • Joined: 23-May 10

Posted 07 June 2011 - 10:41 AM

View Postanthonysomerset, on 07 June 2011 - 06:57 AM, said:

good point thanks for the comments, can you verify that it still works without that extra command in?


Yes. It worked like charm(without the extra command). Also you forgot to mention the part where you have to change your fstab with xvda1 and xvda2 before the first reboot with the new kernel.

This post has been edited by Black: 07 June 2011 - 10:50 AM

0

#16 User is offline   anthonysomerset 

  • On Cloud 9
  • PipPipPip
  • Group: Customers
  • Posts: 618
  • Joined: 16-September 09
  • LocationLondon, UK

Posted 07 June 2011 - 11:09 AM

its not strictly required to change your fstab and at the time i didnt want to risk breaking it, i've since found out that it wont so will add that in too

in fact if you use r1soft you need to use the new mounts to be able to backup your volumes
0

#17 User is offline   Black 

  • I Got Nodes
  • Pip
  • Group: Customers
  • Posts: 7
  • Joined: 23-May 10

Posted 07 June 2011 - 12:45 PM

View Postanthonysomerset, on 07 June 2011 - 11:09 AM, said:

its not strictly required to change your fstab and at the time i didnt want to risk breaking it, i've since found out that it wont so will add that in too

in fact if you use r1soft you need to use the new mounts to be able to backup your volumes


But if you dont change the fstab file, the 1gb default swap wont get activated on boot. It's strange how it's even possible to boot with the sda1 option.
0

#18 User is offline   SilviuB 

  • Newbie
  • Pip
  • Group: Members
  • Posts: 3
  • Joined: 07-July 11

Posted 08 July 2011 - 07:33 AM

When running:
apt-get update && apt-get install linux-image-`uname -r|sed 's,[^-]*-[^-]*-,,'` udev


I get:
Hit http://security.debian.org squeeze/updates Release.gpg
Ign http://security.debian.org squeeze/updates/main Translation-en_US
Ign http://ftp.uk.debian.org Squeeze Release.gpg
Ign http://ftp.uk.debian.org Squeeze/main Translation-en_US
Hit http://ftp.uk.debian.org squeeze-updates Release.gpg
Ign http://ftp.uk.debian.org squeeze-updates/main Translation-en_US
Hit http://security.debian.org squeeze/updates Release
Ign http://ftp.uk.debian.org Squeeze Release
Hit http://ftp.uk.debian.org squeeze-updates Release
Ign http://security.debian.org squeeze/updates/main Packages/DiffIndex
Ign http://ftp.uk.debian.org Squeeze/main Packages
Ign http://ftp.uk.debian.org Squeeze/main Sources
Ign http://security.debian.org squeeze/updates/main Sources/DiffIndex
Hit http://security.debian.org squeeze/updates/main Packages
Hit http://ftp.uk.debian.org squeeze-updates/main Packages/DiffIndex
Hit http://ftp.uk.debian.org squeeze-updates/main Sources/DiffIndex
Ign http://ftp.uk.debian.org Squeeze/main Packages
Hit http://security.debian.org squeeze/updates/main Sources
Ign http://ftp.uk.debian.org Squeeze/main Sources
Hit http://ftp.uk.debian.org squeeze-updates/main Packages
Err http://ftp.uk.debian.org Squeeze/main Packages
  404 Not Found [IP: 83.142.228.128 80]
Err http://ftp.uk.debian.org Squeeze/main Sources
  404 Not Found [IP: 83.142.228.128 80]
W: Failed to fetch http://ftp.uk.debian.org/debian/dists/Squeeze/main/binary-i386/Packages  404 Not Found [IP: 83.142.228.128 80]

W: Failed to fetch http://ftp.uk.debian.org/debian/dists/Squeeze/main/source/Sources  404 Not Found [IP: 83.142.228.128 80]

E: Some index files failed to download, they have been ignored, or old ones used instead.


Where can i find the right paths ?
0

#19 User is offline   anthonysomerset 

  • On Cloud 9
  • PipPipPip
  • Group: Customers
  • Posts: 618
  • Joined: 16-September 09
  • LocationLondon, UK

Posted 08 July 2011 - 10:57 AM

looks like a capital S in the url, check your sources list and make sure its all in lower case :)
0

#20 User is offline   elemental.tm 

  • I Got Nodes
  • PipPip
  • Group: Customers
  • Posts: 18
  • Joined: 08-April 10
  • LocationReading, United Kingdom

Posted 12 July 2011 - 09:52 PM

Hi,

I had the GRUB problem and found this fix before I found this thread. I quote:

"Because Xen manages your kernel on a level that is not visible to the VPS or instance you’re working in, you can just easily remove grub:
apt-get remove grub-legacy grub-common

Simple as that. Now you will be able to manage your system as you normally would, and not worry about constant errors while using apt-get."

I hope this helps. Can some one from VPS/Onapp plse sort out the dam templates so others don't waste time on this! :blink:

orig source
Atomicsprite - Social Media Marketing Management, SEO and Digital Marketing Agency | http://atomicsprite.com | @atomicsprite | Mr Jamie Robinson-Woledge - jamie@atomicsprite.com | +44 7973 855292 | Skype ID jrwoledge | Our Clients AngelDesk – jamie@angeldesk.com | BonusThemes | JoomlaCache | MightyExtensions - jamie@mightyextensions.com | OS Training | SiteMotions
0

Share this topic:


  • (2 Pages)
  • +
  • 1
  • 2
  • You cannot start a new topic
  • This topic is locked

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users