LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 08-15-2011, 08:25 AM   #1
coolx
LQ Newbie
 
Registered: Aug 2011
Posts: 28

Rep: Reputation: Disabled
I cant install or uninstall apache


Hello,
Firstly I am beginner at linux. I had some problems at apache server and then I tryed to uninstall with these command;
---------------------------------------
apt-get remove --purge apache2
---------------------------------------

Then I try lots of install and unintall commands. Now there is nothing in "/etc/apache2" directory. The command's output is below,
When I try to install command, server is not seems installed;
----------------------------------------
root@cacti:/etc/apache2# apt-get install apache2
Reading package lists... Done
Building dependency tree
Reading state information... Done
apache2 is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 169 not upgraded.
-----------------------------------------

Then Im trying to uninstall it, the output is below;
-----------------------------------------
root@cacti:/etc/apache2# apt-get -purge apache2
E: Command line option 'p' [from -purge] is not known.
root@cactitest:/etc/apache2# apt-get purge apache2
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be REMOVED:
apache2*
0 upgraded, 0 newly installed, 1 to remove and 169 not upgraded.
After this operation, 36.9kB disk space will be freed.
Do you want to continue [Y/n]? y
(Reading database ... 146549 files and directories currently installed.)
Removing apache2 ...
---------------------------------------------

And I found these command from net, I think its getting Apache componenents;

---------------------------------------------
root@cactitest:/etc/apache2# dpkg --get-selections | grep apache
apache2-mpm-itk install
apache2-utils install
apache2.2-bin install
apache2.2-common install
libapache2-mod-php5filter install
---------------------------------------------


Why is this so hard to uninstall or install a progra to Linux? Isnt this should be easy like executing a command or clicking a button like in Windows? Or am I doing somethings wrong? Now there is nothing I can do and I still dont know is apache installed or uninstalled? In both ways server is not running.

---------------------------------------------
root@cactitest:/etc/apache2# service apache2 restart
.: 49: Can't open /etc/apache2/envvars
--------------------------------------------
 
Old 08-15-2011, 09:55 AM   #2
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985
you're clearly not typing in the purge command correctly, and it's telling you that:

Quote:
root@cacti:/etc/apache2# apt-get -purge apache2
E: Command line option 'p' [from -purge] is not known.
i.e. it's "apt-get purge apache2" just like you'd already successfully run "apt-get install apache2" without the dash.

uninstalling programs is NOT hard. Make sure it's not your fault before wishing things were more like windows. The same windows where you have to go and identify the package you want to install, go to the right website, find the download link, download the right version of the file and then double click on setup.exe, decompress the installation files to an obscure temp directory, find those files again, run the installer program, then check the license agreement then confirm installation location and installation options etc...

and if you want a gui, try synaptic, amongst others.

Last edited by acid_kewpie; 08-15-2011 at 10:00 AM.
 
Old 08-16-2011, 12:13 AM   #3
coolx
LQ Newbie
 
Registered: Aug 2011
Posts: 28

Original Poster
Rep: Reputation: Disabled
Thanks for your answer acid_kewpie but I tryed "apt-get purge apache2" and it didnt worked too.Is just this command enough for uninstalling completely programs?
 
Old 08-16-2011, 02:54 AM   #4
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985
OK, so where did "purge" come from? I don't use debian / ubuntu so assumed that was the right command, but it doesn't exist - http://linux.die.net/man/8/apt-get

Last edited by acid_kewpie; 08-16-2011 at 02:57 AM.
 
Old 08-16-2011, 06:45 AM   #5
cycocool
LQ Newbie
 
Registered: Jul 2009
Location: Ireland
Distribution: Ubuntu server 14
Posts: 18

Rep: Reputation: 0
hey, just check out this link:

http://net.tutsplus.com/tutorials/ph...rver-for-free/

dont worry about getting rid of apache, this will overwrite whatever you currently have installed. just make sure to read what you are agreeing to.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
uninstall apache? es7us Red Hat 6 09-20-2004 10:28 PM
Redhat 9 - How do I uninstall apache + how do I add apache to autostart? praefex Linux - Software 2 07-29-2003 12:21 PM
Apache Uninstall chandravel Linux - Newbie 1 07-03-2003 01:24 PM
RH8.0 : Need to uninstall Apache 2 and install Apache 1 ericcarlson Linux - Software 1 02-10-2003 02:13 PM
apache uninstall linuxwannabe Linux - Software 2 05-17-2002 02:19 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 06:33 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