LinuxQuestions.org
View the Most Wanted LQ Wiki articles.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Security
User Name
Password
Linux - Security This forum is for all security related questions.
Questions, tips, system compromises, firewalls, etc. are all included here.

Notices

Reply
 
Search this Thread
Old 12-16-2012, 05:36 PM   #1
nobuntu
Member
 
Registered: Mar 2012
Distribution: Debian for server, CrunchBang for everything that's not a server
Posts: 143

Rep: Reputation: 24
Simple Apache/port-forwarding question


Good afternoon,

I am trying to set up a functional LAMP server using CrunchBang 11. My ISP (Cox Communications) seems to have blocked port 80, so I want to run the server on a different port: 8090.

My Linksys router is set up to forward like this: image.

I am wondering which Apache configuration files I need to edit in order to get Apache to let me access http://my-ip-address:8090/, and specifically what to change them to.

I know almost nothing about networking/port-forwarding/Apache, so this project has been very educational. This is the only remaining stumbling-block until I have a functioning LAMP server in my bedroom!

Regards,

/R3nCi/
 
Old 12-16-2012, 08:04 PM   #2
Z038
Member
 
Registered: Jan 2006
Distribution: Slackware
Posts: 786

Rep: Reputation: 157Reputation: 157
You need to locate your httpd.conf file and add a Listen statement to it for the port you want Apache to listen on. There will probably be some commented out examples in it. My httpd.conf is located in /etc/httpd/ directory.

I guess, from your image, that Linksys is referring to the incoming port from the WAN side as the "Externet" port. If so, it looks like you have it forwarded to port 80 on your system. If that is true, then you don't want to tell Apache to listen on 8090. It should listen on 80 since your router is translating it from 8090 to port 80 on your system. If you were to forward an incoming connection on WAN port 8090 to port 8090 on your system, then you'd want Apache to listen on 8090.

After you update httpd.conf, you need to restart Apache. The command is "apachectl -k restart".

BTW, the Linux - Security forum is not really the best place for this question. A moderator may end up moving it.
 
1 members found this post helpful.
Old 12-16-2012, 09:16 PM   #3
frankbell
Guru
 
Registered: Jan 2006
Location: Virginia, USA
Distribution: Slackware, Debian, Mageia, Mint
Posts: 7,315

Rep: Reputation: 1380Reputation: 1380Reputation: 1380Reputation: 1380Reputation: 1380Reputation: 1380Reputation: 1380Reputation: 1380Reputation: 1380Reputation: 1380
In a default XAMPP installation, the httpd.conf file is in /opt/lampp/etc.

The XAMPP stop and start commands, to be issued after cd-ing to /opt/lampp (at least on my system) are

Code:
./lampp stop
./lampp start
as root.
 
1 members found this post helpful.
Old 12-17-2012, 11:40 PM   #4
Z038
Member
 
Registered: Jan 2006
Distribution: Slackware
Posts: 786

Rep: Reputation: 157Reputation: 157
OP, was the information you were provided helpful? Do you have more questions?
 
Old 12-18-2012, 07:10 PM   #5
nobuntu
Member
 
Registered: Mar 2012
Distribution: Debian for server, CrunchBang for everything that's not a server
Posts: 143

Original Poster
Rep: Reputation: 24
Quote:
Originally Posted by Z038 View Post
OP, was the information you were provided helpful? Do you have more questions?
I have no further questions. Thank you to everyone who has helped me.

Secondarily: my apologies for posting this in the Security forum. I meant topost it inLinux - Server, but must have selected the wrong subforum accidentally. I was very tired at the time...
 
  


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
Simple port forwarding question abentkov Linux - Networking 5 12-11-2012 10:42 AM
simple port forwarding with iptables ratcateme Linux - Networking 1 01-12-2009 04:05 PM
simple port forwarding SPEEDEX Linux - Networking 1 09-28-2007 11:20 AM
Simple Port Forwarding Firewall - not forwarding MadTurki Linux - Security 14 04-09-2006 12:08 PM
How can I do simple port forwarding on RH9? yetalu Linux - Networking 4 07-14-2003 07:44 PM


All times are GMT -5. The time now is 08:16 AM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration