sufehmi

Debian Snapshot - usage example

Jan 21st, 2017
312
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. # an example on how to use Debian Snapshot
  2. # this example will install PHP version 5.3.10-2
  3. # ====================
  4.  
  5. # make sure /etc/apt/sources.list already got these lines in it :
  6.  
  7. ## PHP 5.3.10-2 packages
  8. # deb http://snapshot.debian.org/archive/debian/20120221T041601Z/ unstable main
  9. ## Apache 2.22.2-1 packages
  10. # deb http://snapshot.debian.org/archive/debian/20120202T040408Z/ unstable main
  11.  
  12. # why these lines ? see "Usage" on http://snapshot.debian.org for info
  13. # more info : http://mstd.eu/index.php/2016/07/04/install-old-versions-of-software-on-debian-like-php-5-3/
  14. # ===================
  15.  
  16. # remove current PHP packages
  17. sudo apt-get remove --purge `dpkg -l | grep php | grep -w 5.5 | awk '{print $2}' | xargs`
  18. # remove current Apache packages
  19. sudo apt-get remove --purge `dpkg -l | grep apache | grep -w 2 | awk '{print $2}' | xargs`
  20.  
  21. # update package database
  22. apt-get update
  23.  
  24. # this is the setting required to be able to use Debian Snapshot
  25. apt-get -o Acquire::Check-Valid-Until=false update
  26.  
  27. # now we can specify the exact version
  28. apt-get install php5=5.3.10-2 libapache2-mod-php5=5.3.10-2 php5-cli=5.3.10-2 php5-common=5.3.10-2 php5-gd=5.3.10-2  php5-mcrypt=5.3.10-2 php5-mysql=5.3.10-2 php5-pgsql=5.3.10-2 apache2=2.2.22-1  apache2-mpm-prefork=2.2.22-1 apache2-suexec=2.2.22-1    apache2-utils=2.2.22-1   apache2.2-common=2.2.22-1  apache2.2-bin=2.2.22-1
  29.  
  30. /etc/init.d/apache2 restart
RAW Paste Data

Adblocker detected! Please consider disabling it...

We've detected AdBlock Plus or some other adblocking software preventing Pastebin.com from fully loading.

We don't have any obnoxious sound, or popup ads, we actively block these annoying types of ads!

Please add Pastebin.com to your ad blocker whitelist or disable your adblocking software.

×