LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 01-30-2012, 11:48 AM   #1
peturkarl
LQ Newbie
 
Registered: Mar 2011
Location: Iceland
Distribution: Debian
Posts: 9

Rep: Reputation: 0
Revert to fresh Debian install


Quick and easy question, how would you guys recommend I do this, purge&remove "all" packages?

Just need SSH access.
 
Old 01-30-2012, 01:54 PM   #2
pljvaldez
LQ Guru
 
Registered: Dec 2005
Location: Somewhere on the String
Distribution: Debian Wheezy (x86)
Posts: 6,094

Rep: Reputation: 281Reputation: 281Reputation: 281
If you can get your hands on the machine, it's probably best to just reinstall with a netinstall CD, then in tasksel unselect all groups except "base system".

You could try dpkg --get-selections > packages.txt and then change everything you want to remove from "installed" to "purge". Then do a dpkg --set-selections < packages.txt.

Or you could try install tasksel from the repos and uncheck all the boxes.

Or if you don't care about the hard disk space, you could simply modify the init scripts so that nothing starts up at boot.

Last edited by pljvaldez; 01-30-2012 at 01:55 PM.
 
Old 01-31-2012, 04:58 AM   #3
peturkarl
LQ Newbie
 
Registered: Mar 2011
Location: Iceland
Distribution: Debian
Posts: 9

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by pljvaldez View Post
If you can get your hands on the machine, it's probably best to just reinstall with a netinstall CD, then in tasksel unselect all groups except "base system".

You could try dpkg --get-selections > packages.txt and then change everything you want to remove from "installed" to "purge". Then do a dpkg --set-selections < packages.txt.

Or you could try install tasksel from the repos and uncheck all the boxes.

Or if you don't care about the hard disk space, you could simply modify the init scripts so that nothing starts up at boot.
thanks for your reply, im afraid physical tampering is out of the question. It's a VPS, im leaning towards just removing all the necessary packages manually.
 
Old 01-31-2012, 05:04 AM   #4
zhjim
Senior Member
 
Registered: Oct 2004
Distribution: Debian Squeeze x86_64
Posts: 1,748
Blog Entries: 11

Rep: Reputation: 233Reputation: 233Reputation: 233
For a manual removale maybe this comes handy.
Code:
dpkg -l > /tmp/all_your_installed_packages
for i in $(cat /tmp/all_your_installed_packages; do
         some_command_to_remove_the_version
         apt-get purge $i
done
Edited cause its dpkg and not dpg

Last edited by zhjim; 02-01-2012 at 02:19 AM.
 
Old 01-31-2012, 04:28 PM   #5
peturkarl
LQ Newbie
 
Registered: Mar 2011
Location: Iceland
Distribution: Debian
Posts: 9

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by zhjim View Post
For a manual removale maybe this comes handy.
Code:
dpg -l > /tmp/all_your_installed_packages
for i in $(cat /tmp/all_your_installed_packages; do
         some_command_to_remove_the_version
         apt-get purge $i
done
Thanks will probably do something like that.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Help on fresh install of Debian 6.0.1 sr_25 Debian 10 03-26-2011 01:36 AM
X won't start after fresh Debian install Rahiiyja Linux - Newbie 12 01-14-2007 09:41 AM
Fresh debian-etch install rangalo Debian 5 12-25-2006 11:47 AM
Fresh Install Debian 31r2 / 2.4 or 2.6?? DagonSphere Debian 4 05-06-2006 01:23 PM
Fresh Debian install locks while starting up Imek Debian 1 10-02-2004 07:36 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 07:56 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration