Many people are looking for how to start using a Webserver.
Here is the way I did it. Maybe you can use this step by step instruction.
You must Use static IP address on your Qnap.
I use 10.0.0.90 as an example in this instruction.
You have to use one static IPadress in your iprange.
Before you open your Qnas for webusers, it`s strenghtly recommended to change all password on your Qnas.
My own policy is to have min. 8 letters and numbers mixed in the password for the users and Admin accounts.
Please follow the steeps one by one to setup your Webserver.
- Enable webserver in the adminpanel for your server.
After enabling you have to use port 8080 to reach your servers Adminpanel.
Let`s say your servers local IPadress is 10.0.0.90
To reach the adminpanel you only write http://10.0.0.90 in the browser.
After enabling the webserver you have to write http://10.0.0.90:8080/ in the browser.
Tips: It`s smart to create shortcut under favorits for the panel. -
- - Open port 80 from WAN to your local Qnap port 80 in your router.
You can visit http://portforward.com/ for help.
Some broadband providers have instruction for this on their websites.
I send mail to my provider, and they send me full instruction for the router they had delivered to me.
If your provider deliver a router to you, i think they have the configuration for this to.
-
-
- - To Check your nat mapping, Please type your Wan IPadress in the browser.
If you wonder what is your Wan ip. Visit http://whatismyip.com
Copy this IPaddress into your webbrowsers addressline and press enter
If you see your Nas homepage, you have done everything right.
If there is problems with the port forwarding of your router, you can visit http://portforward.com/ for help.
-
-
- - Now it`s time too create your own dynamic address.
This will make it a lot easyer to find your webpage.
If you use only your dynamic IP address, this will chage after a couple of days.
Then you have to give all your friends the new IPaddress.
Dynamic domain address will eliminate this problem.
Go to http://dyndns.com, and create your own nice address.
If you need help with this, I have made one Tuorial for DYNDNS to.
DYNDNS Tutorial for Qnap: http://forum.qnap.com/viewtopic.php?f=32&t=11816
It`s altso possible to use some other dynamic address providers.
Take care of the address, username and password for later use in the Qnas.
-
-
- - You will later se that you have to do some changes of the files in the apache server on the Qnas.
To make configuration of the files inside the apache server you need some software. I use WinSCP 4.1.8 to do this.
You can find this at http://winscp.net/eng/index.php
Download and install this on your local computer.
This will we use later in this tutorial.
Tutorial for WinSCP is here: http://forum.qnap.com/viewtopic.php?f=32&t=11200
-
-
- - Start your adminpanel on Qnas i the browser writing http://10.0.0.90:8080/
Go to administration -> Network Settings -> DDNS Service
Add your username, password and hostname in the fields.
If you wonder what hostname is, this is the DNS address you created earlier on the dyndns.com page.
I use "Check the external IP address automatically" every 15 minutes. -
-
- - Now you are ready to upload your files to the webserver.
Enable the FTP service under Qnaps Adminpanel
You can leave all the settings as default an just press Apply
Use flashFXP or some other FTP program to upload files.
Every file and folders must be in the share Qweb to make it visible on the internet.
The startpage must have the name index.html, index.htm or index.php
-
-
-
Problems I meet under the configuration.
-
-
- - It is not possible to reach the files from web without using the / after the adress.-
This problem is not with the new firmware 3. Please go to point 12
-
- - To fix this / problem you have to log on to the apache server. Be careful innside this program, and please dont`t delete any files.
Start WinSCP and log in to your Qnap.
I use the local IPadress for this. 10.0.0.90
Log on with your admin username and password.
-
Tutorial for WinSCP you will find here: http://forum.qnap.com/viewtopic.php?f=32&t=11200
Here you will also find How to backup file before editing. This is absolutely recommended before editing.
-
-
On the right side you will se all the files and folders on your Qnas.
This looks not the same as from the windows browser.
On the right side is all the files of your Qnas.
On the left side is all your files and folder on your local computer.
Find the ICON Root on top of the view. It looks like a folder, and with a slash / across.
Press this button, and you will start from root on the filetree in the Qnas -
Open folder Mnt -> HDA_ROOT -> .config -> apache
-
Now you see some files in the right window.
Open the file apache.conf
Browse inside of the file, and find
-
-
<Directory "/share/Qweb">
Options FollowSymLinks MultiViews
AllowOverride None
Order allow,deny
Allow from all
-
Change the line AllowOverride None to AllowOverride All
-
Like this
<Directory "/share/Qweb">
Options FollowSymLinks MultiViews
AllowOverride All
Order allow,deny
Allow from all
-
- - Find the line UseCanonicalName On and change this to UseCanonicalName Off in your apache.conf file
Save and close the file.
This wil fix: Subdirectories only working with a slash "/" at the end of the URL,
This problem is not with the new firmware 3. Please go to point 12
-
and now there will be no problems with the slash "/" after the adress
It will also be possible to use .htaccess files if you need it later.
-
-
- - Now you need to restart your Apache server.
Go to the WinSCP program, and find the terminal icon.
Look at the black icon on the WinSCP program.
Either you can press CTRL + T then it starts. Answere yes if the program ask if its ok to start another session.
In the terminal line you type this command an press enter
/etc/init.d/./Qthttpd.sh restart
Then you see the apacheserver restarts. I only takes a couple of seconds.
If you are afraid to do this, you can restart the QNas server in normal way in the adminpanel.
Just find the button restart under System Tools. This will be the same but takes more time.
-
-
-
This changes is all you need in the first time. Close the WinSCP program, and hopefully everything works fine.
-
-
- - checking your ISP for port blocking in the Firewall
I did not have this problem my self, but it`s possible to read about this in the post below this one from danieldegeorge
The topic: http://forum.qnap.com/viewtopic.php?f=3 ... 584#p52790
It seems he had problems with his ISP, and had to do some changes in there internal firewall.
He just opended the ports in the 'Internal Firewall Protection' from the ISP Toolbox. Which allowed the ports from his Router to be forwarded correctly.
I would just like to say thank you to Daniledegeorge for the Addon, and hope more people will add problems they have come across.
This problem with ISP, I hope not so many will meet. This will only happen with some ISP`s that have high security measurements.
Please be patient, and check with your provider if this could be a posible problem. They should have the solution for this.
-
-
- - Now you can try visit your homepage with your new hostname. http://yourname.dyndns.info or something.
-
-
- - To be totaly sure this works you can do this.
Visit the page http://www.the-cloak.com/login.html and write your hostadress and press start surfing. Now you can see how it looks against a proxyserver. If this works fine, then everything is OK and you are ready to build your hompage.
-
-
- - If there is something I have missed here please tell me and I will add this to the instruction.
Please be patient with my english to .
Any other problems you can search for in the forum.
- Adminpanel for Qnas = The administration panel you find if you log on to http://serverlocalip/ or http://serverlocalip:8080
- WinSCP = Program to do changes of the files inside the Apacheserver.
- Terminal window = Application you can run in the WinSCP program. Press CTRL + T when WinSCP is active.
- Router = Your broadband router
- WAN = Is the iprange outside of your router
- LAN = Is the iprange innside of your router
Tags:configuration, webserver , make, create, homepage, start webserver, change port in router, download WinSCP, change apache.config, edit webserver, install webserver, web server win scp, dynamic, webadress, ipadress, Fix Subdirectories only working with a slash "/" at the end of the URL