Stem_Cell
11/11/13 03:20AM
Zyii said:
Its been a terrible past week, and I can reaffirm my dislike for my current job.

Gonna try to repace myself with this because I've had little to no time at all that I could dedicate myself to the server work. //zooms//

Don't worry, hypnohub is the place where overworked people can gather and sob in unison, lol.

Zyii said:
Alright so I made the file and I uploaded it to the server in the /var/www directory, but the site still looks the same to me. How can I double check that its working or not? Unless the fact that nothing happened means that the PHP isn't installed?

There is a root folder by itself though, but it doesn't have an index.html file in it.

I'm not sure if I understand - there is a /var/www folder with an index.html file, right? In any case, that's where the server is currently serving stuff from. That is the "root directory" when you access it via web, so, if you put a "test.php" there, you should be able to access it as "the-site.net/test.php". What happens if you do that?
Zyii
11/11/13 03:39AM
Stem_Cell said:
Don't worry, hypnohub is the place where overworked people can gather and sob in unison, lol.


//singletear

Stem_Cell said:
I'm not sure if I understand - there is a /var/www folder with an index.html file, right? In any case, that's where the server is currently serving stuff from. That is the "root directory" when you access it via web, so, if you put a "test.php" there, you should be able to access it as "the-site.net/test.php". What happens if you do that?



Yeah I put the file there. And I had a lapse in how to access the files, I forgot I could do that ahahaorz When I pull up the page i get the code back in my face, so I'm guessing it doesn't work then
Stem_Cell
11/11/13 06:16AM
Ok, we just need to install PHP. For clarification, LAMP actually works like this:

* Linux is the OS where everything is running, such as...
* Apache, an HTTP server that handles web requests, letting...
* PHP parse them to send results back to the browser, and uses...
* MySQL as a database engine (to store posts, etc. in a fast way).

In reality Linux is not the only OS, Apache is not the only HTTP server, PHP is not the only language and MySQL is not the only database engine, so you could substitute all of the above, but the model still remains.

For example, Nginx is an alternative to Apache that is faster, at the expense of being less compatible with some code you'll find out there (that may rely on some Apache-specific modules like mod_rewrite)

I believe that you can install LAMP by running this command through SSH:

apt-get install lamp-server^

(the caret at the end is part of the command).

Run that and tell me what happens. It may ask for things like choosing a database password, etc. - you can choose whatever options you want, but take note of them, and of any default option you just accept.
Zyii
11/11/13 06:34AM
Not sure if it worked... I did it through the PuTTY program and got this when I did:


Reading package lists... Done
Building dependency tree... Done
E: Unable to locate package lamp-server^
E: Couldn't find task 'lamp-server'
E: Couldn't find any package by regex 'lamp-server^'
[thing]@[site]:~#


Stem_Cell
11/11/13 12:14PM
Oh by the way, sorry, I forgot that you may have to update the software lists. The package manager keeps a list of all software out there. So you might need to run:

apt-get update

and then run

apt-get install lamp-server^


Also, whenever you wish to upgrade all the software in your Ubuntu at once (like if a newer stable version of PHP, Apache, MySQL, or pretty much whatever else is installed), you just have to run

apt-get update
apt-get upgrade


(Also I assume you're logged in as "root", which is denoted by a command-line starting with a # sign instead of a $ sign (normal user), else you'd need to run all these commands prefixed by "sudo" (like "sudo apt-get ...") and providing your password as necessary.)
Zyii
11/11/13 05:44PM
answering from work because i realize i have time for it during my breaks thankfully;;

i'll be sure to do that when i get home, and yeah i am logged in as root. im not even sure how to create another account thing for it anyway. :B

this is all very interesting though, bit of a pain to get set up but im guessing its easier as its set up right?
Zyii
11/11/13 09:53PM
Yay~! I got it working and I see the page correctly now! <3

Alrighty, now I start looking for the software right? Not sure how I'd install it though, but hopefully there are directions when I find the one i want right? I'm not sure if its the fact I'm running on 2 hours of sleep and a 5 hour energy but I'm excited now! ;w;
Stem_Cell
11/12/13 12:09AM
Zyii said:
i'll be sure to do that when i get home, and yeah i am logged in as root. im not even sure how to create another account thing for it anyway. :B

If you ever want to, you just have to run

useradd johntitor

For the user to have a home directory too, it would need to be

useradd -d /home/johntitor -m johntitor

And adding a password is

passwd johntitor

And then you type the desired password as asked.

Zyii said:
this is all very interesting though, bit of a pain to get set up but im guessing its easier as its set up right?

Yes, and if you think about it, being in control of your own server to do as you wish is pretty nice, huh? And the update process is also really nice - the other day I updated a Linux Mint box that was left to rot for a few months, and it downloaded thousands of packages and installed them in a matter of minutes. If you compare that to Windows Update, that doesn't even update more than the core system and takes the whole day and several reboots...

Also, another nice thing about Linux: you don't need to reboot it. You might need to re-start a daemon (service), like the HTTP server, to do things like installing modules, but the whole machine doesn't usually need reboots, and can be on-line for years on end. It's still possible to reboot it (the command is "reboot"), and you might realise that your VPS will perform a reboot and be on-line again in a matter of some 5 seconds, but it's not necessary.

Another plus is that you don't need an anti-virus, and did I mention that you can choose from a variety of filesystems, most of which (like the default ext4) are immune to fragmentation and self-healing? Linux is great when you get used to it.

Zyii said:
Yay~! I got it working and I see the page correctly now! <3

That is awesome! Do you see in that "PHP Info" page something about MySQL? Just to be sure that it's installed. <<ubuntuhandbook.org/wp-con...13/10/php-mysql-works.jpg|Like this>>?

In that case you only need to find some forum software you like. Most of them have an "installation" page, sometimes they have some requirement (like PHP 5.4+), but it's almost certain that you fulfill the requirements, because LAMP on Ubuntu is very standard.

I can help you with installing once you find one you like :)
Stem_Cell
11/12/13 12:11AM
Zyii said:
I'm not sure if its the fact I'm running on 2 hours of sleep and a 5 hour energy but I'm excited now! ;w;

Oh, and, try to sleep well too! 2 hours is so little :(
Zyii
11/12/13 12:36AM
Stem_Cell said:
Oh, and, try to sleep well too! 2 hours is so little :(



It was my fault for staying up late and then not being able to sleep when i finally did;;;


Stem_Cell said:

Yes, and if you think about it, being in control of your own server to do as you wish is pretty nice, huh?


It feels AMAZING I'm not gonna lie ;w;

Hopefully once I get the first site up, will start on the second domain and see if I can incorporate some other things I wanted. (like a lowscale minecraft server for my friends and myself or something like that to dabble in)

Stem_Cell said:
That is awesome! Do you see in that "PHP Info" page something about MySQL? Just to be sure that it's installed. <<ubuntuhandbook.org/wp-con...13/10/php-mysql-works.jpg|Like this>>?

In that case you only need to find some forum software you like. Most of them have an "installation" page, sometimes they have some requirement (like PHP 5.4+), but it's almost certain that you fulfill the requirements, because LAMP on Ubuntu is very standard.


Yep I saw a PHP info page with a bunch of info! Software, I was stuck between phpBB and IPB, but I'm gonna try phpBB.
Stem_Cell said:
I can help you with installing once you find one you like :)


Speaking of that, do you have a skype or something similar to that I can talk to you on? I don't wanna rush/bother you if you don't wanna give me yours but I just kinda wanna get the site running before I have to work again in a couple days;; ;w;
Zyii
11/12/13 01:47AM
Huh, I can't seem to find where the files would go installation-wise using the FTP program...

I made a subdomain (I think) for the site because I like things being organized and stuff, but I can't seem to find the folder for it, even though I'm looking at where the server says it is?
Stem_Cell
11/12/13 06:02AM
Zyii said:
It feels AMAZING I'm not gonna lie ;w;

Hopefully once I get the first site up, will start on the second domain and see if I can incorporate some other things I wanted. (like a lowscale minecraft server for my friends and myself or something like that to dabble in)

That's the spirit!

Zyii said:
Yep I saw a PHP info page with a bunch of info! Software, I was stuck between phpBB and IPB, but I'm gonna try phpBB.

By the way, I'm specifically talking about being a section saying "MySQL", like this:
i.imgur.com/2DLcYQm.jpg

(it would mean MySQL is correctly installed).

Zyii said:
Speaking of that, do you have a skype or something similar to that I can talk to you on? I don't wanna rush/bother you if you don't wanna give me yours but I just kinda wanna get the site running before I have to work again in a couple days;; ;w;

Actually I don't - no IM client or Skype installed, and I don't even use Facebook, Twitter, G+, etc. :P

Zyii said:
Huh, I can't seem to find where the files would go installation-wise using the FTP program...

I made a subdomain (I think) for the site because I like things being organized and stuff, but I can't seem to find the folder for it, even though I'm looking at where the server says it is?

Making a subdomain involves editing an Apache configuration file too (not only on the domain name servers) - so that it knows where to load files from. It is pretty simple; there's a command-line text editor called nano. You can use it to edit Apache's configuration file like this:


nano /etc/apache2/sites-available/nameofyoursitehere


That will open a command-line text editor, you can paste text by right mouse button.

You should paste something like this:

NameVirtualHost *:80

<VirtualHost *:80>
DocumentRoot /path/to/new/site
ServerName name.of.your.site.here.net
</VirtualHost>


Then press Ctrl+X and save, then you can make the directory for the site with:


mkdir -p /path/to/new/site


(you could use /var/nameofyoursitehere or something, as the site's root directory)

And enable the site with:

a2ensite nameofyoursitehere


Then restart Apache:

service apache2 restart


That would create a subdomain or separate domain that you'd be able to use :) (even more top-level domains if that was left unclear).

As for installing PHPBB, I'll look into it.
Stem_Cell
11/12/13 06:08AM
Oh, by the way. Installing PHPBB might be easier than I thought, because it is in the "Universe" repository. This also means it will be magically updated for you and will install any necessary dependency.

Isn't Linux such a beautiful thing?

You just have to run:


apt-get install phpbb3


:)
Zyii
11/12/13 07:16PM
Stem_Cell said:

By the way, I'm specifically talking about being a section saying "MySQL", like this:
i.imgur.com/2DLcYQm.jpg



Yep, found that section and it seems to be working from what your example says!

Stem_Cell said:

Actually I don't - no IM client or Skype installed, and I don't even use Facebook, Twitter, G+, etc. :P



Ah alright, just curious ;w;

Stem_Cell said:

there's a command-line text editor called nano.



When I tried the command, it said that the command wasn't found.. But I tried doing:

apt-get install nano


And I think it worked, so I'm trying out the commands you gave now~

Stem_Cell said:
Oh, by the way. Installing PHPBB might be easier than I thought, because it is in the "Universe" repository. This also means it will be magically updated for you and will install any necessary dependency.

Isn't Linux such a beautiful thing?

You just have to run:

apt-get install phpbb3

:)


It really is <3

Installed correctly~ I guess I don't need this zip of the files or do I still need those for any reason?

EDIT: for the /path/to/new/site i give the one the cpanel provided me with right?
Stem_Cell
11/13/13 11:39AM
Zyii said:
When I tried the command, it said that the command wasn't found.. But I tried doing:
apt-get install nano

And I think it worked, so I'm trying out the commands you gave now~

See, you can install all sorts of stuff like that!

Also, since you seem to be getting a hang of it, so a few tips:

* You can search packages with:
apt-cache search whatever-you-want-to-search

* You can update all your packages with
apt-get upgrade

* Before package operations, you might want to run
apt-get update
(note that it's different from upgrade) to make sure the package lists are up-to-date.
* The Bash command-line kicks ass, and one of the ways it does that is it features really comprehensive tab-completion! It means that you can hit the tab key to see what characters might complete whatever you're typing. If there's more than one option, you'll hear a ding and you may tab a second time to show all possible options (it will complete until the part where it's still unambiguous).

Zyii said:
Installed correctly~ I guess I don't need this zip of the files or do I still need those for any reason?

No, it should be installed already :)

Zyii said:
EDIT: for the /path/to/new/site i give the one the cpanel provided me with right?

It should only necessary to go that route if you want subdomains / separate domains, but, what cPanel, did RamNode's cPanel configure Apache on your VPS by itself? (I honestly don't know since I didn't try it out).
<<<12 3 4>>>


Reply | Forum Index