LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu
User Name
Password
Ubuntu This forum is for the discussion of Ubuntu Linux.

Notices


Reply
  Search this Thread
Old 10-12-2015, 01:43 PM   #1
djgnoriega2
LQ Newbie
 
Registered: Oct 2015
Posts: 2

Rep: Reputation: Disabled
problems uninstalling postfix


Hello,
I have problems with the installation of postfix on my server.
IRedMail initially install on my server with Ubuntu 14.0 LTS.
Then uninstall iRedMail with the official procedure.
Perform an upgrade to the successful system.
Now I try to install Postfix and does not finish the installation:
Step 1:
sudo apt-get install postfix
Reading package lists ... Done
Building dependency tree
Reading state information ... Done
Already postfix is ​​the newest version.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

Step 2:
I try to start postfix settings and displays error.
sudo dpkg-reconfigure postfix
invoke-rc.d: initscript unknown, /etc/init.d/postfix not found.

If I try to uninstall postfix error occurs:
sudo apt-get remove postfix
Reading package lists ... Done
Building dependency tree ... 50%
Building dependency tree
Reading state information ... Done
The following packages will be REMOVED:
**postfix
0 upgraded, 0 newly installed, 1 to remove and 0 not upgraded.
After This operation, 3,609 kB disk space will be freed.
(Reading database ... 95534 files and directories currently are installed.)
Removing postfix (2.11.0-1ubuntu1) ...
invoke-rc.d: initscript unknown, /etc/init.d/postfix not found.
dpkg: error processing postfix package (--remove):
*subprocess installed pre-removal script returned error exit status 100
Errors Were Encountered while processing:
*postfix
E: Sub-process / usr / bin / dpkg returned an error code (1)


I need to uninstall and reinstall postfix.
 
Old 10-12-2015, 02:35 PM   #2
berndbausch
LQ Addict
 
Registered: Nov 2013
Location: Tokyo
Distribution: Mostly Ubuntu and Centos
Posts: 6,316

Rep: Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002
Your problem is that /etc/init.d/postfix has disappeared. That makes it impossible to automatically shutdown postfix before removing it.

Try apt-get --reinstall install postfix. This will force installation although it's already on your system.
 
Old 10-12-2015, 05:18 PM   #3
djgnoriega2
LQ Newbie
 
Registered: Oct 2015
Posts: 2

Original Poster
Rep: Reputation: Disabled
root@vipertwo:~# apt-get --reinstall install postfix
Reading package lists... Done
Building dependency tree
Reading state information... Done
0 upgraded, 0 newly installed, 1 reinstalled, 0 to remove and 0 not upgraded.
Need to get 0 B/1,084 kB of archives.
After this operation, 0 B of additional disk space will be used.
Preconfiguring packages ...
Selecting previously unselected package postfix.
(Reading database ... 95534 files and directories currently installed.)
Preparing to unpack .../postfix_2.11.0-1ubuntu1_amd64.deb ...
invoke-rc.d: unknown initscript, /etc/init.d/postfix not found.
dpkg: warning: subprocess old pre-removal script returned error exit status 100
dpkg: trying script from the new package instead ...
dpkg: ... it looks like that went OK
grep: /etc/postfix/master.cf: No such file or directory
grep: /etc/postfix/master.cf: No such file or directory
Unpacking postfix (2.11.0-1ubuntu1) over (2.11.0-1ubuntu1) ...
Processing triggers for ufw (0.34~rc-0ubuntu2) ...
Processing triggers for ureadahead (0.100.0-16) ...
Processing triggers for man-db (2.6.7.1-1ubuntu1) ...
Setting up postfix (2.11.0-1ubuntu1) ...
update-rc.d: /etc/init.d/postfix: file does not exist
dpkg: error processing package postfix (--configure):
subprocess installed post-installation script returned error exit status 1
Processing triggers for libc-bin (2.19-0ubuntu6.6) ...
Errors were encountered while processing:
postfix
E: Sub-process /usr/bin/dpkg returned an error code (1)
 
Old 10-12-2015, 10:49 PM   #4
berndbausch
LQ Addict
 
Registered: Nov 2013
Location: Tokyo
Distribution: Mostly Ubuntu and Centos
Posts: 6,316

Rep: Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002
My misunderstanding, sorry. --reinstall still attempts to remove the package. I don't know how to prevent apt-get or dpkg from performing the pre-remove task, but here are two ideas:
  • Copy /etc/init.d/postfix from a working system (preferred)
  • Create a dummy /etc/init.d/postfix containing just the line "exit 0", and ensure no postfix processes are running
Then try apt-get remove again.
 
  


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
uninstalling postfix in RH uninstalls newaliases theodore12 Linux - Software 1 01-21-2009 08:42 AM
uninstalling and partitioning problems wolfinator Linux - Laptop and Netbook 1 07-24-2006 02:46 PM
Uninstalling Linux problems. N Z Russell Linux - General 5 02-10-2004 08:17 AM
uninstalling problems tearinox Linux - Newbie 2 08-04-2003 03:11 PM
Problems Uninstalling RealPlayer Kindness Linux - Software 1 07-08-2003 07:02 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu

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