How to host my website on my linode

I am new to linode.

I have linode account.

I have rebuilded linode with Ubuntu 10.04 LTS.

I am connected via putty to linode.

How can I host My website on my linode using Lamp?

I have done some steps.

  • Set the hostname

  • Install and configure the Apache Web Server

etc.

I am following this guide.

http://library.linode.com/lamp-guides/u … tual-hosts">http://library.linode.com/lamp-guides/ubuntu-10.04-lucid#sph_configure-name-based-virtual-hosts

Please help.

6 Replies

What are you stuck on and what have you tried that didn't work?

Thanks for reply Matth.

Let me explain what steps I have already done.

http://library.linode.com/getting-started

According to this manual

After having linode account,

I have

  • Deployed a Linux Distribution Ubuntu 10.04 LTS

  • Started My Linode using reboot

  • As I am on windows xp, I have downloaded PUTTY, Using that connected to my linode

  • After that Installed Security Updates using given commands in manual

  • then Set the Hostname to teamnim

After that using http://library.linode.com/lamp-guides/u … 0.04-lucid">http://library.linode.com/lamp-guides/ubuntu-10.04-lucid

I have made following updations

Set up a LAMP Server on Ubuntu 10.04

  • Set the Hostname

  • Install and Configure the Apache Web Server

  • Configure Name-based Virtual Hosts

  • Install and Configure the MySQL Database Server

  • Install and Configure PHP

But when I run '/etc/init.d/apache2 restart' OR '/etc/init.d/apache2 reload'

I get following message

  • Restarting web server apache2

apache2: aprsockaddrinfo_get() failed for teamnim

apache2: Could not reliably determine the server's fully qualified domain name, using 127.0.0.1 for ServerName

… waiting apache2: aprsockaddrinfo_get() failed for teamnim

apache2: Could not reliably determine the server's fully qualified domain name, using 127.0.0.1 for ServerName

Also if I type any command with sudo

I got this error: sudo: unable to resolve host teamnim

/etc/PHP5/apache2/PHP.ini

This command gives me error : -bash: /etc/PHP5/apache2/PHP.ini: No such file or directory

Please help

1. What do you get as output when you do "hostname -f"?

2. Regarding sudo, EVERY command? so "sudo ls" gives you that error as well? Follow this

3. php.ini isn't an executable. You have to open it with something (an editor, like nano) - also, it's case sensitive. So:

nano /etc/php5/apache2/php.ini

Add sudo infront of that if you have no writing permissions.

Are you sure it isn't easier to get someone to admin your Linode? Correct me if I'm wrong, but you don't seem like someone who has a lot of experience with the CLI. It might be better to get someone to do it for you.

Unless of course it's a playbox, but if it's important websites that have to run it that might be wiser.

@Nuvini Thanks for reply

Using Putty I connected to linode.

And on that command prompt I logged in.

My root is root@teamnim

If I execute this command

root@teamnim:/# hostname -f

I get

hostname: Name or service not known

If I execute sudo ls

root@teamnim:/# sudo ls

sudo: unable to resolve host teamnim

bin cdrom etc home lost+found mnt proc sbin srv tmp var

boot dev example.org lib media opt root selinux sys usr

Yes you are absolutely right that I am fresher for all these things.

I have website that is developed in PHP-Mysql.

and want to host this website on linode. That's it.

for that I have followed documention. Accordingly made configurations, settings.

Hi,

Since some things seem messed up, and you have only just started with your Linode, it's probably better to make sure it's done right and use a stackscript.

The Linode stackscripts do the configuration automatically, so you're certain it's set up properly.

Doing this will WIPE everything you have so far, but at least it will 100% work.

Please check here: http://www.linode.com/stackscripts/view … criptID=10">http://www.linode.com/stackscripts/view/?StackScriptID=10

After that, the only thing you might need to do is manually change the hostname /Virtual host to reflect your hostname, if you don't have a reverse DNS yet.

If you do have a domain, set up the Reverse DNS first: https://manager.linode.com/linodes/remote_access/Nuvini

After that, I believe the stackscript puts the webroot at /srv/www//public_html/

Good luck,

PS. If I were you I'd use Debian 6. The hostname error you had was apperantly a bug limited to Ubuntu.

The workings are pretty much the same command-wise, since Ubuntu is based on Debian.

@manisha:

Using Putty I connected to linode.

And on that command prompt I logged in.

My root is root@teamnim

If I execute this command

root@teamnim:/# hostname -f

It seems your path is / when you log in instead of /root… something strange happend with your installation.

I would install the system again.

Reply

Please enter an answer
Tips:

You can mention users to notify them: @username

You can use Markdown to format your question. For more examples see the Markdown Cheatsheet.

> I’m a blockquote.

I’m a blockquote.

[I'm a link] (https://www.google.com)

I'm a link

**I am bold** I am bold

*I am italicized* I am italicized

Community Code of Conduct