LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 12-04-2016, 08:09 AM   #1
hack3rcon
Senior Member
 
Registered: Jan 2015
Posts: 1,432

Rep: Reputation: 11
Post Why Port 25 is open on Debian 8.6?


Hello.
I installed Debian 8.6 amd64 and when I Nmap my system then Nmap tell me that Port 25 is Open!!! If I disable this service can it cause any problem?

Thank you.
 
Old 12-04-2016, 01:06 PM   #2
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
Quote:
Originally Posted by hack3rcon View Post
Hello.
I installed Debian 8.6 amd64 and when I Nmap my system then Nmap tell me that Port 25 is Open!!! If I disable this service can it cause any problem?

Thank you.
Hi,

Post 25 is the default smtp port. If you don't want to use your box as a mail server, you can disable postix:
Code:
sudo service postfix stop;
sudo update-rc.d postfix disable;
Regards
 
Old 12-05-2016, 01:10 AM   #3
hack3rcon
Senior Member
 
Registered: Jan 2015
Posts: 1,432

Original Poster
Rep: Reputation: 11
Quote:
Originally Posted by bathory View Post
Hi,

Post 25 is the default smtp port. If you don't want to use your box as a mail server, you can disable postix:
Code:
sudo service postfix stop;
sudo update-rc.d postfix disable;
Regards
Thank you a lot.
I used "sudo systemctl disable postfix" can it enough? I don't like it start automatically at boot.
 
Old 12-05-2016, 01:46 AM   #4
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 21,804

Rep: Reputation: 7306Reputation: 7306Reputation: 7306Reputation: 7306Reputation: 7306Reputation: 7306Reputation: 7306Reputation: 7306Reputation: 7306Reputation: 7306Reputation: 7306
you can simply check it by rebooting your box. Was that enough?
 
Old 12-05-2016, 03:19 AM   #5
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
Quote:
Originally Posted by hack3rcon View Post
Thank you a lot.
I used "sudo systemctl disable postfix" can it enough? I don't like it start automatically at boot.
If you're using systemd it should be enough.

Regards
 
Old 12-05-2016, 06:49 AM   #6
hack3rcon
Senior Member
 
Registered: Jan 2015
Posts: 1,432

Original Poster
Rep: Reputation: 11
Quote:
Originally Posted by bathory View Post
If you're using systemd it should be enough.

Regards
I did it but when I reboot my system then "Nmap" said me port 25 is open!!!
It is an output of "nc":
Code:
nc localhost -v 25
localhost [127.0.0.1] 25 (smtp) open
220 Xen-aka-X3n ESMTP Exim 4.84_2 Sun, 04 Dec 2016 16:17:42 -0800
Code:
sudo service postfix stop
[sudo] password for jason: 
Failed to stop postfix.service: Unit postfix.service not loaded.
 
Old 12-05-2016, 07:28 AM   #7
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
Quote:
nc localhost -v 25
localhost [127.0.0.1] 25 (smtp) open
220 Xen-aka-X3n ESMTP Exim 4.84_2 Sun, 04 Dec 2016 16:17:42 -0800

sudo service postfix stop
[sudo] password for jason:
Failed to stop postfix.service: Unit postfix.service not loaded.
From the nc output looks like you're running exim and not postfix, so replace postfix with exim in the commands above
 
Old 12-05-2016, 09:16 AM   #8
hack3rcon
Senior Member
 
Registered: Jan 2015
Posts: 1,432

Original Poster
Rep: Reputation: 11
Quote:
Originally Posted by bathory View Post
From the nc output looks like you're running exim and not postfix, so replace postfix with exim in the commands above
I did:
Code:
sudo systemctl disable exim
And reboot my system but problem exist:
Code:
nc localhost -v 25
localhost [127.0.0.1] 25 (smtp) open
220 Xen-aka-X3n ESMTP Exim 4.84_2 Sun, 04 Dec 2016 18:42:14 -0800
 
Old 12-05-2016, 11:45 AM   #9
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
Quote:
I did:

sudo systemctl disable exim

And reboot my system but problem exist:
Apparently the service is called exim4 nowadays, so use:
Code:
sudo systemctl disable exim4
 
1 members found this post helpful.
Old 12-05-2016, 12:44 PM   #10
sundialsvcs
LQ Guru
 
Registered: Feb 2004
Location: SE Tennessee, USA
Distribution: Gentoo, LFS
Posts: 10,649
Blog Entries: 4

Rep: Reputation: 3934Reputation: 3934Reputation: 3934Reputation: 3934Reputation: 3934Reputation: 3934Reputation: 3934Reputation: 3934Reputation: 3934Reputation: 3934Reputation: 3934
Umm, it is a fairly simple matter to ps -A and look at the list of daemons and other processes that are running.

When you initially install your Linux system, you should first very carefully ponder exactly what daemons you actually wish to run. Sure, there are a handful of "canned choices," but you don't in fact need to choose any one of them.

Please(!) understand that I mean absolutely nothing personal when I observe:
Quote:
Your system's configuration must be, not an easy choice, but a conscious one!"

"Know what you run, and know
why you run it!"

Last edited by sundialsvcs; 12-05-2016 at 12:45 PM.
 
Old 12-06-2016, 12:39 AM   #11
hack3rcon
Senior Member
 
Registered: Jan 2015
Posts: 1,432

Original Poster
Rep: Reputation: 11
Quote:
Originally Posted by bathory View Post
Apparently the service is called exim4 nowadays, so use:
Code:
sudo systemctl disable exim4
Thank you. Problem solved.
 
  


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
PPTP VPN on Debian VPS (port 1723 Not Open) SubZeroJake Linux - Networking 13 05-13-2012 11:00 PM
[SOLVED] need to open port number 7 on debian linux gadhave.vikas Linux - General 18 05-14-2011 03:05 AM
CentOS 5: iptables - cannot open port 80 and nat to port 8080 for Tomcat steve willett Linux - Networking 4 09-24-2010 04:03 AM
debian iptables squid - redirect port 80 to port 8080 on another machine nickleus Linux - Networking 1 08-17-2006 12:59 AM
cannot SFTP to SUSE 9.2 box, port 22 open, can putty in though using same port. jgrady Linux - Networking 6 03-29-2005 08:44 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

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