How to install and run Apache web server in Ubuntu Linux
HTML-код
- Опубликовано: 21 авг 2024
- A quick and easy tutorial on downloading installing and running Apache web server in Ubuntu 11.10 Linux. I also cover verifying the server, starting and stopping Apache, as well as editing the index.html homepage.
Go here for Part 2 Installing PHP to the Apache web server: • Install PHP to an Apac...
Please subscribe and visit me at: danscourses.com where I have more tutorials on Linux
Thanks Dan for the simple , useful tutorial. I just ran this install on a Mint laptop and noticed a few things that were slightly different from the video. I Installed Apache 2.4. The index.html is now at /var/www/html/index.html Another difference was with noted in the terminal output of the 'netstsat -a | more' section of the video. The output didn't show the *:www OR 127.0.0.1:80 with tcp, but showed :::80 on tcp6. Navigating to localhost or pinging 127.0.0.1 worked however. I figured I'd leave these observations for others so they might not get discouraged. Cheers and thanks again.
John Kirk thanks i thought i was the only one
Thank you so much @John Kirk you saved my ass!
THANKS
Awesome tutorial, I especially appreciate the clear microphone and the good accent.
yes, finally no indian.
Lmao
@@Glori4n what problem do you have with India
@@jethalalnhk2409 No one has problems with India or anyone personally, it can be hard to understand many Indian people's voices. It's normal and any Computer Science graduate can thank at least one Southern Asian for helping them with one or more modules.
@@Glori4n 7⁷⁸8uà88ī
Great video. Only thing that I had to do was install nano. This video already has nano installed. Just sudo apt-get install nano and you will be fine. Also if you find just "html" instead of index.html you have to change directory to the html "cd /html" and then ls. You'll see the index.html in there to edit.
Many many many thanks! 7 years later still the best guide.
This is helpful even in 2020. Thank you for the clear instructions.
bro, how use apache2 like htdocs ? can show folder localhost
this is really helpful sir.I saw all of your videos on cisco paket tracer and i finished the major project with its help.Now for my linux project im referring this video.I have never seen someone explain this so clearly.Thank u sir and keep up the good work.
make sure you include sudo at the beginnign of the installation command so that you have root user access
Dan is just out of normal......he is just gifted!!!
Excellent! I rate this video 10/10, great tutorial, streaight to the point not like other people just keep talking talking and give you nothing at the end.
from another computer (on the network), try putting in the webserver's ip address in the web browser and hit enter. You should be able to pull up the webserver's homepage thereby reaching the webserver from another location.
Is ther something like a local DNS Server so i can set it up to redirect a choosen name e.g. mypage.localnetwork to that ip adress?
crisp and clear tutorial on Apache web server I have ever come across.. Thanks a lot for this
This is a straightforward installation, but outdated for the newer releases of Ubuntu. Example, no longer need to access init.d to restart the service, this can be done in systemctl apache2.
Sure, but you probably want to put your Ubuntu web server in a DMZ first just in case it is vulnerable and gets hacked. You want to make sure it is not wide open but locked down tight. Regardless, security concerns aside, all you need to do if set up port-forwarding on your router so that all requests to your router ip address on port 80 are forwarded to your Ubuntu webserver's private ip address on port 80.
Hey Dan. You are awesome. Thank you. Reading instructions is so much harder than watching a video. Just followed your instructions and built my own site. My goal is to install Wikimedia and add extensions. Once I learn this I can take this to work and update our mediawiki version and extensions. :)
Thank you for this insightful and useful tutorial. Can please tell me what program you used to take the screen capture and also capture your voice in Ubuntu? Perhaps you could create a video about this if it is more complex than simply downloading the best software for doing this? Thanks again.
simple and clear steps --- thanks
*installs apache2* *watches video* *types server ip address in browser* *screams with delight* I LOVEZ LINUX.
Gracias! thks, it was very helpful and I'm glad you didn't skip steps so it was pretty clear, almost all went well except that it stills shows the "It works" page regardless of the modification I did to it
Thanks for your video. I was unable to get that IP but this video solved all the problems. I am setting up server in Ubuntu 18.4.
I type sudo service apache2 stop/start/status. However I think that you're safer using Dan's sudo /etc... method.
Great video, sound and clear! Thank you so much.
use the touch command to create the file from the terminal. "touch index.html" while in the appropriate directory
You should keep your web server's IP address private, but portforward port 80 requests to your router's public IP address, through your router, to your web server IP address on port 80
Clear and easy to understand
There is "gedit" in Ubuntu -- better editor, best for beginners and not only for them.
Tip: when you type: gedit filename & you will receive the editor (like workpad) and still have you CLI Free to check out your output without close it.
Very helpful to me and well explained with clear audio.
This is really really good. Well Done Dan!
You don't need a beast of a computer to run a web server. I run one from a Raspberry Pi.
I found this video very useful. Thanks for having kindly generated it and shared it :)
Can you make a complete tutorial on apache, means what files need to be configured to run a website. It will be a great help for all newbies like me.
just wanna say thay u r great!!!! love your vid's! all are explaind very clearly and profetionly.thanks alot
Thank you Dans. You are genereous and pedagogic
Awesome vid Dan !! Keep up the great work.
Great video! So simple and easy to follow. You mention setting up a domain in this video. Can you provide where you talk about this? Thanks.
very nice to watch. Learnt many many things. I wish you will present many more.
very straight forward and easy flow...thankss
Clear tutorial! Love it.
Great video man.Helped a lot!
Nice tutorial. just started using linux
Thanks for the video! I have a question though. So, I installed apache2 and everything started ok, but when I do the netstat I do not see the 0.0.0.0:80 line in the list at all, like its not listening on port 80. Shouldn't this be setup by default after installing and starting apache? Any advice?
Dan Roden sure! go into /etc/apache2/ports.conf and ensure that there you can find the "Listen 80" text inside the file. if not, add it, save the file then restart the webserver.:)
How do I do this??:
Inside, at the bottom of the file, add a ServerName directive, pointing to your primary domain name. If you do not have a domain name associated with your server, you can use your server's public IP address:
Note
If you don't know your server's IP address, skip down to the section on how to find your server's public IP address to find it.
/etc/apache2/apache2.conf
. . .
ServerName server_domain_or_IP
Nice Video! Is this available only at localhost, only on the local network or worldwide?
شكرا جزيلا لك .... لقد نفعني كثيرا هذا الدرس
Make sure to type "sudo apt-get install nano" in your root directory if the nano command doesn't work for you. I had to do that.
Sir, great videos. Thank you for sharing your knowledge!
Simple and perfect
Thank's a lot
great, someone already loves you! Very clear, very helpful, I'm glad I found you... more on Linux please
great tutorial, first time running apache, and linux for the matter. First time using the terminal was to install apache2. easy to follow along with you. im using 12.04 ubuntu.. Ran into a snag though, how do i make an index.html file in the var directory if it isn't there?
my goodness that looked easy.
Such an awesome video, thank you sooooo much
Nice 100/100 for this video
Wow cool. Do you know how to connect the web server to windows 2012 domain?
good idea, sure!
Super useful, thank you.
Thank you a lot . Good learning .
*Excellent video-tutorial :)*
VERY HELPFUL
well done its very good content for nibbies.....
awesome tutorial!
Great work, thanks.
hi, I suddenly wonder that I did quite well by doing step-by-step in your instructions. but in step of nano index.html. it's nothing there, I mean it doesn't have a form of basic html page, so How can I do to fix it? Many thanks
Hi I tried to setup for Slitaz webser..But it says "The default configuration is to allow connections only from local host so port 80 is not open for security reasons"...How to I open port 80 from accessing it outside.
can we change the address of server to some IP address ?
I know this was four ago but in case you somehow still don't know the answer, you can but you would have to purchase a domain. I recommend Google Domains because they are cheap, reliable, secure, and great customer support!
very useful for noobs like me, thnx
excellent sir
nice video, i think portable version apps also work fine
Awesome vid, helps me alot, i already have a domain name (from godaddy) pointing to my IP(not the machine ip the IP provided by my internet provider) but i also have a netgear router inbetween.
So the question is how would i have the apache server listen on my main IP and not go through the router, OR how would i setup a port forwarding/port triggering so it goes through the router.
And (just getting basic) how would i change the port apache is listening on?
Very helpful, thank you :D
This is a great tutorial and really helped.
What if my server is listening on a different port and not to www either. Mine says *:5900 and netbios-ssn. I installed gadmin-proftd and whenever I make it port 80 it deactivates. Any help would be great.
Is there any way you could make a short video on this topic? I've done all the port forwarding and checked my confs but I still can't get this to work. I feel like I'm missing something really simple.
I can view the default webpage on my local ip address but the netstat command doesnt show port 80 being listened. what can cause this?
I replaced the index.html and other files in that directory to my own files, and now it always says forbidden in my web browser. Any ideas?
great ... Now there is apache, running on my ubuntu system , The stop command does not work that you showed , and I canot edit the index.html file , with the commands you showed. !!!!
I am trying to configure apache2. I'm not quite sure what I'm reading in the guides. What are the steps to configure it?
My terminal hangs whenever I use netstat -a | more however it works whenever I use -an instead :/
Just fyi for folks - I had to install apache2-example-pages in addition to apache2 to get the 'It Works' file.
Hi, How to fix error while installing wine, clamak, apache2 etc?
error: "N: Ignoring file 'getdeb.list.bck' in directory '/etc/apt/sources.list.d/' as it has an invalid filename extension N: Ignoring file 'getdeb.list.bck' in directory '/etc/apt/sources.list.d/' as it has an invalid filename extension"
thank you, very nice tut,
mine does not appear to be listening to everything that your's is... at least not that I can see. Is that a problem?
does apache works without VirtualBox , i installed the vitualBox but every time type virtual box --version it gives "" The character device /dev/vboxdrv does not exist.
Please install the virtualbox-dkms package and the appropriate
headers, most likely linux-headers-generic.
"
what to do ?
Hi i can not edit the html. It says it works and it has the ubuntu logo and all this other information very different from yours
Very Good video thank you.!!!
dude, thank you so much!
Awesome, thank you
It's not showing my laptop that it is listening to port 80 . What can I do ?
8 years later, is this still actual?
I am wondering the same
How could i install neo4j instead of mysql and connect it through php?
I'm on mac os X, I was following the code up to the point where you cd /var/www. I cannot find the html.index file anywhere in my directory. If you can help me out it would be a big help. Great video, thanks!
+SoapBox SoftWare I know this is an older thread, however, I'll still offer what little help I can on the subject. The file should be labeled index.html. Where .html is the file extension.
How can I have multiple instance like xampp offers multiple folders
Thank you Dan
What if I want to consult this server externally? with the public ip?
how do i change the port to 8080
i already have a service running on 80
When I use the netstat command the terminal returns only the headers (Proto, Recv-Q, etc.), but no actual port data. Anyone have any clues as to what's going on with my distro?
Thanks!
My page says unable to connect instead of the page saying it worked.
How would you add host headers? So you can use your own URL?
Dan i am using ubuntu 12.04. it doesnt have gui interface. how to check wheather it is working or not.
I have already updated to PHP7.0 but I cannot switch back to PHP when I tried to open phpmyadmin.... who can help?
thank's a lot,! good job
ubuntu server: apache2 cant open localhost page on windows 7
i m working on VM machine where i configure W28 enterpris with Ubuntu server with local dhcp for windows 7.
but when i try to open localhost page cant open in firefox
pls help sir
That was amazing