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

Комментарии • 239

  • @JohnKirk
    @JohnKirk 10 лет назад +46

    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.

  • @vadim-horatiu3478
    @vadim-horatiu3478 9 лет назад +140

    Awesome tutorial, I especially appreciate the clear microphone and the good accent.

    • @Glori4n
      @Glori4n 4 года назад +13

      yes, finally no indian.

    • @bradyredding1964
      @bradyredding1964 3 года назад +1

      Lmao

    • @jethalalnhk2409
      @jethalalnhk2409 3 года назад +6

      @@Glori4n what problem do you have with India

    • @master0fnone
      @master0fnone 3 года назад +5

      @@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.

    • @babludas8113
      @babludas8113 3 года назад

      @@Glori4n 7⁷⁸8uà88ī

  • @BTphosheezy
    @BTphosheezy 7 лет назад +10

    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.

  • @Bainzoo
    @Bainzoo 5 лет назад +1

    Many many many thanks! 7 years later still the best guide.

  • @gwenobenza8820
    @gwenobenza8820 4 года назад +17

    This is helpful even in 2020. Thank you for the clear instructions.

    • @taufiknurrahman2590
      @taufiknurrahman2590 3 года назад

      bro, how use apache2 like htdocs ? can show folder localhost

  • @directedsoulgames326
    @directedsoulgames326 7 лет назад

    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.

  • @danscourses
    @danscourses  11 лет назад +5

    make sure you include sudo at the beginnign of the installation command so that you have root user access

  • @ramirez368
    @ramirez368 4 года назад +1

    Dan is just out of normal......he is just gifted!!!

  • @clicktech1062
    @clicktech1062 4 года назад +3

    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.

  • @danscourses
    @danscourses  11 лет назад +3

    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.

    • @thomasre8073
      @thomasre8073 3 года назад

      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?

  • @sam-fm6jz
    @sam-fm6jz 5 лет назад

    crisp and clear tutorial on Apache web server I have ever come across.. Thanks a lot for this

  • @DaMu24
    @DaMu24 3 года назад

    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.

  • @danscourses
    @danscourses  11 лет назад

    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.

  • @ruexotic
    @ruexotic 11 лет назад

    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. :)

  • @Larry_Druhall
    @Larry_Druhall 6 дней назад

    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.

  • @samuelaraya7140
    @samuelaraya7140 9 лет назад +8

    simple and clear steps --- thanks

  • @aomimezura11
    @aomimezura11 11 лет назад

    *installs apache2* *watches video* *types server ip address in browser* *screams with delight* I LOVEZ LINUX.

  • @alexandrabruges9321
    @alexandrabruges9321 5 лет назад

    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

  • @sangamshrestha143
    @sangamshrestha143 6 лет назад

    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.

  • @StephanieG1
    @StephanieG1 11 лет назад +1

    I type sudo service apache2 stop/start/status. However I think that you're safer using Dan's sudo /etc... method.

  • @igrieger
    @igrieger 11 лет назад +2

    Great video, sound and clear! Thank you so much.

  • @ryanmsusa
    @ryanmsusa 11 лет назад

    use the touch command to create the file from the terminal. "touch index.html" while in the appropriate directory

  • @danscourses
    @danscourses  11 лет назад

    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

  • @Isabel-dm1gy
    @Isabel-dm1gy 4 года назад

    Clear and easy to understand

  • @DJFireSam
    @DJFireSam 11 лет назад

    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.

  • @AngelCintiaRockgirl
    @AngelCintiaRockgirl 5 лет назад

    Very helpful to me and well explained with clear audio.

  • @benedictsimpson6953
    @benedictsimpson6953 4 года назад

    This is really really good. Well Done Dan!

  • @kevinbaum3040
    @kevinbaum3040 10 лет назад +2

    You don't need a beast of a computer to run a web server. I run one from a Raspberry Pi.

  • @jdeb0016
    @jdeb0016 8 лет назад

    I found this video very useful. Thanks for having kindly generated it and shared it :)

  • @umairksa2011
    @umairksa2011 11 лет назад

    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.

  • @cohen23ran
    @cohen23ran 7 лет назад

    just wanna say thay u r great!!!! love your vid's! all are explaind very clearly and profetionly.thanks alot

  • @MrNDOYES
    @MrNDOYES 11 лет назад

    Thank you Dans. You are genereous and pedagogic

  • @JoeGancher
    @JoeGancher 9 лет назад

    Awesome vid Dan !! Keep up the great work.

  • @adobebeefarm8596
    @adobebeefarm8596 8 лет назад

    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.

  • @MamunurRashidMd
    @MamunurRashidMd 11 лет назад

    very nice to watch. Learnt many many things. I wish you will present many more.

  • @sonalihiranandani965
    @sonalihiranandani965 8 лет назад

    very straight forward and easy flow...thankss

  • @oranxd5616
    @oranxd5616 6 лет назад

    Clear tutorial! Love it.

  • @rohil1993
    @rohil1993 10 лет назад

    Great video man.Helped a lot!

  • @HighTierWitches
    @HighTierWitches 6 лет назад

    Nice tutorial. just started using linux

  • @danroden8561
    @danroden8561 9 лет назад +5

    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?

    • @Horvbalix
      @Horvbalix 7 лет назад

      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.:)

    • @osamabindrinkin40s
      @osamabindrinkin40s 7 лет назад

      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

  • @al3xandros.c
    @al3xandros.c 4 года назад

    Nice Video! Is this available only at localhost, only on the local network or worldwide?

  • @Exotic0101
    @Exotic0101 11 лет назад

    شكرا جزيلا لك .... لقد نفعني كثيرا هذا الدرس

  • @tuggifmusic
    @tuggifmusic 11 лет назад

    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.

  • @mazdysoraya6121
    @mazdysoraya6121 11 лет назад

    Sir, great videos. Thank you for sharing your knowledge!

  • @jacquesmaire30
    @jacquesmaire30 3 года назад

    Simple and perfect
    Thank's a lot

  • @jemmaj2919
    @jemmaj2919 6 лет назад

    great, someone already loves you! Very clear, very helpful, I'm glad I found you... more on Linux please

  • @charlesoconnor08
    @charlesoconnor08 11 лет назад

    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?

  • @MSKChess
    @MSKChess 5 лет назад +1

    my goodness that looked easy.

  • @celinebaka-chat8394
    @celinebaka-chat8394 6 лет назад

    Such an awesome video, thank you sooooo much

  • @microcodes6887
    @microcodes6887 2 года назад

    Nice 100/100 for this video

  • @raghavsood6156
    @raghavsood6156 8 лет назад +1

    Wow cool. Do you know how to connect the web server to windows 2012 domain?

  • @danscourses
    @danscourses  12 лет назад

    good idea, sure!

  • @MarkRileyem
    @MarkRileyem 8 лет назад

    Super useful, thank you.

  • @nazmulahmed8584
    @nazmulahmed8584 6 лет назад

    Thank you a lot . Good learning .

  • @learitee444
    @learitee444 7 лет назад

    *Excellent video-tutorial :)*

  • @iffattasnim4440
    @iffattasnim4440 10 лет назад +1

    VERY HELPFUL

  • @gunjanyadav1408
    @gunjanyadav1408 9 лет назад

    well done its very good content for nibbies.....

  • @sangeethaanbarasan1930
    @sangeethaanbarasan1930 4 года назад

    awesome tutorial!

  • @mjandali3608
    @mjandali3608 3 года назад

    Great work, thanks.

  • @thohoang9383
    @thohoang9383 10 лет назад

    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

  • @kuldeepsarma763
    @kuldeepsarma763 8 лет назад

    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.

  • @AshokKumar-ug2ze
    @AshokKumar-ug2ze 10 лет назад +2

    can we change the address of server to some IP address ?

    • @Jishy
      @Jishy 5 лет назад

      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!

  • @butthead128
    @butthead128 10 лет назад +2

    very useful for noobs like me, thnx

  • @ashishdhiman5177
    @ashishdhiman5177 4 года назад

    excellent sir

  • @Technispace
    @Technispace 7 лет назад

    nice video, i think portable version apps also work fine

  • @JoXDDFive
    @JoXDDFive 12 лет назад

    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?

  • @nir61202
    @nir61202 7 лет назад

    Very helpful, thank you :D

  • @Keishidojo
    @Keishidojo 8 лет назад

    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.

  • @balls2balls
    @balls2balls 11 лет назад

    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.

  • @gordon1201
    @gordon1201 12 лет назад

    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?

  • @thebaconbox1
    @thebaconbox1 7 лет назад

    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?

  • @derekp5257
    @derekp5257 11 лет назад

    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. !!!!

  • @kathymckinney3162
    @kathymckinney3162 6 лет назад

    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?

  • @lordquas70
    @lordquas70 5 лет назад

    My terminal hangs whenever I use netstat -a | more however it works whenever I use -an instead :/

  • @tmdpc
    @tmdpc 11 лет назад

    Just fyi for folks - I had to install apache2-example-pages in addition to apache2 to get the 'It Works' file.

  • @michalwojtyniak3691
    @michalwojtyniak3691 9 лет назад

    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"

  • @CompBioQuest
    @CompBioQuest 11 лет назад

    thank you, very nice tut,

  • @chris082681
    @chris082681 11 лет назад

    mine does not appear to be listening to everything that your's is... at least not that I can see. Is that a problem?

  • @LifeInRailway_withHarish
    @LifeInRailway_withHarish 7 лет назад

    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 ?

  • @lottoman562
    @lottoman562 9 лет назад

    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

  • @vasilisnikitaras
    @vasilisnikitaras 8 лет назад

    Very Good video thank you.!!!

  • @Dudarinho
    @Dudarinho 7 лет назад

    dude, thank you so much!

  • @josejgopar
    @josejgopar 6 лет назад

    Awesome, thank you

  • @madhavkumarpancholi9842
    @madhavkumarpancholi9842 3 года назад

    It's not showing my laptop that it is listening to port 80 . What can I do ?

  • @kjell5352
    @kjell5352 4 года назад +1

    8 years later, is this still actual?

  • @kuntalkumardey7028
    @kuntalkumardey7028 7 лет назад

    How could i install neo4j instead of mysql and connect it through php?

  • @XxlegerityxX
    @XxlegerityxX 10 лет назад

    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!

    • @TechnomancerTheWise
      @TechnomancerTheWise 9 лет назад

      +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.

  • @kennethjohn9759
    @kennethjohn9759 8 лет назад

    How can I have multiple instance like xampp offers multiple folders

  • @t3kang
    @t3kang 8 лет назад

    Thank you Dan

  • @leandroDroguett
    @leandroDroguett 4 года назад

    What if I want to consult this server externally? with the public ip?

  • @logangraham2956
    @logangraham2956 4 года назад

    how do i change the port to 8080
    i already have a service running on 80

  • @milliconsolutions5377
    @milliconsolutions5377 3 года назад

    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?

  • @abdullahyousef3596
    @abdullahyousef3596 9 месяцев назад

    Thanks!

  • @masmin4316
    @masmin4316 6 лет назад

    My page says unable to connect instead of the page saying it worked.

  • @spencerwattamaniuk950
    @spencerwattamaniuk950 5 лет назад

    How would you add host headers? So you can use your own URL?

  • @Aman2111
    @Aman2111 11 лет назад

    Dan i am using ubuntu 12.04. it doesnt have gui interface. how to check wheather it is working or not.

  • @mingyan8081
    @mingyan8081 8 лет назад

    I have already updated to PHP7.0 but I cannot switch back to PHP when I tried to open phpmyadmin.... who can help?

  • @hanaemourinou3042
    @hanaemourinou3042 7 лет назад

    thank's a lot,! good job

  • @Hindi61
    @Hindi61 11 лет назад

    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

  • @MSKChess
    @MSKChess 6 лет назад

    That was amazing