Welcome to the GoFuckYourself.com - Adult Webmaster Forum forums. You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today! If you have any problems with the registration process or your account login, please contact us. |
|
Discuss what's fucking going on, and which programs are best and worst. One-time "program" announcements from "established" webmasters are allowed. |
|
Thread Tools |
07-05-2017, 04:25 PM | #1 |
Confirmed User
Industry Role:
Join Date: Apr 2014
Posts: 385
|
How to manage a vps
As you can guess from the title, I'm thinking of taking an unmanaged VPS (eg. digitalocean), I have already tried in the past, with CentOS 6 and CWP (CentOS Web panel), I have not had very different results from a hosting, and then after a few months I closed it.
Now many of your tips to my posts lead me to a VPS, so I'm thinking of trying it again. But I would like to start well, possibly avoiding as many errors as possible. I need some advice, for example: Use a software like cpanel or CWP (or other free) or do everything from command line? Or what else? Using Apache or Litespeed? Use tool like varnish reverse proxy? What to do absolutely? What to avoid absolutely? What is needed to not consume too much resources? etc, etc, etc... I think I can do it all by myself (with the right guides), but please help me to take at least the correct initial direction. |
07-05-2017, 05:14 PM | #2 |
God Bless You
Industry Role:
Join Date: Aug 2014
Location: Glasgow, $cotland
Posts: 1,467
|
I can strong recommend serverpilot i use with vultr, digitalocean and linode - paid and free option - I never get any problems. for me is a best option to manage vps.
__________________
magneto664 📧 gmail.com Adult Backlinks 💘Best Website Stats 💘 Best CDN for Adult Content My Fav: 👍Chaturbate 👍 Stripchat 👍 Dateprofits 👍 AdultFriendFinder |
07-05-2017, 05:24 PM | #3 |
Confirmed User
Industry Role:
Join Date: Sep 2015
Posts: 88
|
If you didn't saw a difference, there are many things to consider before making assumptions, like how the software was written.
If you have background processes, like a newsletter or video encoder, you should see a difference (even with your current setup though). 1. Open to the public only what you have to. Use the command line as it will use less resources. A reason to use CPanel is if there are other managers, or it is more productive. 2. Litespeed looks promising, but I never use it so I can't advise. 3. Yes, for caching. Also read on these topics: 1. Security, specifically on SSH access and firewall. 2. Databases (access control, backups). 3. Caching (HTTP caching if you are hosting the media and not using a CDN). 4. Timezones Lnode and Digital Ocean have some good tutorials. There are YouTube videos as well: https://www.youtube.com/watch?v=oFduaKmAEbg |
07-05-2017, 11:14 PM | #4 |
Too lazy to set a custom title
Industry Role:
Join Date: Feb 2005
Posts: 17,167
|
Not sure what you mean by "I have not had very different results from a hosting". What difference did you expect?
Hosting your money sites on unmanaged server and trying to manage it "with the right guides" isn't a good idea. Looks like you need a fully managed solution or hire someone who knows what they are doing. |
07-05-2017, 11:31 PM | #5 |
Confirmed User
Industry Role:
Join Date: Apr 2004
Posts: 5,711
|
seems like you are CLUELESS and have no idea how to properly manage a server so why not get a fully managed VPS? It costs a bit more but you can sleep better... or are you really that BROKE and can't afford to pay a few bucks more for a fully managed plan?
__________________
--- |
07-06-2017, 12:03 AM | #6 | |
Too lazy to set a custom title
Industry Role:
Join Date: Feb 2005
Posts: 17,167
|
Quote:
|
|
07-06-2017, 03:55 AM | #7 |
God Bless You
Industry Role:
Join Date: Aug 2014
Location: Glasgow, $cotland
Posts: 1,467
|
Yes, some basic knowledge is necessary, After a long time using (2y) I never do any hard server management - all updates and security is a serverpilot job. I always use backups from vps hosting provider and work mostly on wordpress. Even a 10usd option per month give you amazing support. I don't even remember any issues.
__________________
magneto664 📧 gmail.com Adult Backlinks 💘Best Website Stats 💘 Best CDN for Adult Content My Fav: 👍Chaturbate 👍 Stripchat 👍 Dateprofits 👍 AdultFriendFinder |
07-07-2017, 05:25 PM | #8 | |||
Confirmed User
Industry Role:
Join Date: Apr 2014
Posts: 385
|
Wow thanks for the replies, I didn't expect so many. I try to answer everyone in one post.
I gave a look at serverpilot, but I do not understand what it does... I can't find screenshots, guides, anything... Basically serverpilot installs in your place a server in digitalocean with serverpilot panel? It is not like Cpanel? Preferably wordpress, and to you remains only to monitor the server? In this case, I need more autonomy. My sites for work requiring substantially only php, mysql and cronjob. Quote:
This time is different, I want to move to digitalocean my vps Quote:
Lately this problem "Mysql-open-file-limit-100000" https://gfy.com/webmaster-q-and-fucki...-100000-a.html. The last one I purchased on hawkhost every so often decides to do something that consumes all the cpu (normal operation of my sites consumes about 10% of the cpu) and restrict all of my sites and no one can explain why. This creates a lot of problems to google When for an period, my vps worked properly, my sites also arrived at the 20000, 30000, or 50000 visits a day, now 2000-3000, and when they start to increase something breaks... and I'm pretty sure that is not a problem of my sites consumption of resources because in the last few years I have changed 4-5 vps from different providers and it is always some different bullshit that creates problems. Quote:
I can install apache, php and mysql etc, the one that I don't know is for example if it is worthwhile to install varnish or not from the point of view of the server. In the sense that it definitely brings benefits to the sites, but maybe, varnish use a lot of resources or consumes too much cpu... I really need this type of advice to set up a server. I am afraid of some problems or particular errors that the server may have (ex: "Mysql-open-file-limit 100000"), but also with the managed vps they have never come to a solution. I always open a ticket in support and: The first responses to the ticket are always: buy more resources and give me more money. The next are: will it be a problem of the code please contact your developer (me). Then usually respond with some bullshit to take time. Then comes an idiot who doesn't want to read all of the ticke and still responds to: buy new services, please contact the developer. And usually at this point I send them to hell. The assistance is only for simple things, for particular problems do not have the desire or ability to find a solution. Or at least, I never found one that was able to solve serious problems. The only real solution is always to change vps, and hope that in the new vps, everything is working. Often I even found myself the solution, but I have not been able to apply because I did not have the necessary access or permissions of the server, and also suggesting to support have done nothing. Of this, what do you think CentOS Web Panel | Free Linux Web Hosting Control Panel Always thinking from the server side. To me it looks not bad, I used it in my tests and in general I have not had any major problems. But maybe it consumes too many resources, or some gap? Es. suPHP, is it good or not? I don't know ... There is also a support, forum, tickets, etc., even if this tends to send often to the paid service. However, you can pay only when you need it. Sorry if I have dwelt. Thanks for the replies. |
|||
07-08-2017, 02:12 AM | #9 |
Confirmed User
Industry Role:
Join Date: Mar 2013
Location: Internet
Posts: 2,423
|
I use serverpilot and I am very happy with that ! Plus I have some basic linux knowledges!
__________________
Make Money With: Chaturbate |
07-09-2017, 06:08 AM | #10 |
It's 42
Industry Role:
Join Date: Jun 2010
Location: Global
Posts: 18,083
|
Buy a $5 mo instance in the Cloud VPS
Make a subdomain named dev.yourdomain.tld point the 'A' in your current server's dns for that subdomain to the new server IP. set the new server's dns to that subdomain and its 'A' IP I would install Ubuntu 16.04 LTS others will argue their favorite os CentOS is another commonly used. open a SSH session and change to root user get to work Digitalocean and Linode have tutorials search out what you need to do. unix.stackexchange.com is a good source. Google is your friend -- use it. when dev.yourdomain.tld seems to be working to your satisfaction -- from that location -- I am assuming /path/yourdomain.tld/dev; cd to [......]/dev $ cp -R * ../ copy recursively the site files up a level to the main (parent) domain's directory create a new server configuration for the parent domain on the new server change your DNS 'A' for the parent domain on the old server add the parent domain to the DNS new VPS server with the new server's 'A'. Migration of the HTTP part and the MySQL is now complete? Or, pay for a managed VPS server and and do the things that you are good at now. Using a control panel on a VPS or dedicated server is like using a leaky condom IMHO -- You can't feel a thing and it leaks all over the place |
07-10-2017, 02:13 AM | #11 |
So Fucking Banned
Industry Role:
Join Date: Jan 2012
Posts: 768
|
See my sig. They provide full management at a cheap monthly price (transfer to the new location included).
|
07-13-2017, 04:38 PM | #12 |
Confirmed User
Industry Role:
Join Date: Apr 2014
Posts: 385
|
So, these days I'm thinking about Digitalocean, maybe with panel, maybe not.
I would be interested in a panel especially to be able to monitor my sites. Exist anything that allows you to do everything from command line but with statistics and graphs for monitoring? |
07-13-2017, 05:26 PM | #13 |
It's 42
Industry Role:
Join Date: Jun 2010
Location: Global
Posts: 18,083
|
|
07-14-2017, 03:56 AM | #14 |
God Bless You
Industry Role:
Join Date: Aug 2014
Location: Glasgow, $cotland
Posts: 1,467
|
for vps monitoring I recommend https://nixstats.com
__________________
magneto664 📧 gmail.com Adult Backlinks 💘Best Website Stats 💘 Best CDN for Adult Content My Fav: 👍Chaturbate 👍 Stripchat 👍 Dateprofits 👍 AdultFriendFinder |
07-19-2017, 10:16 AM | #15 |
Confirmed User
Industry Role:
Join Date: May 2017
Location: California
Posts: 133
|
If you do not know how to manage a server then I would not recommend getting an unmanaged VPS.
If you want to learn how to manage a server then I would recommend installing a virtual machine and learning the ropes locally on your computer instead of learning on a live product. Having an un managed VPS is a decent solution however it can be much cheaper and easier to scale an AWS EC2 Cloud Instance, which is very similar to having an un-managed vps but you have a lot more control and options. |
07-20-2017, 12:20 PM | #16 |
It's 42
Industry Role:
Join Date: Jun 2010
Location: Global
Posts: 18,083
|
Better yet, install LINUX on an old computer and start learning.
I would recommend Ubuntu as there is a large Internet knowledge base to learn from -- Debian commands work too. If you decide later to use another LINUX operating system on a host server adapting most of the commands will be easy. You can open a terminal and practice -- SSH is just a remote terminal program. |
07-21-2017, 02:28 AM | #17 |
Registered User
Industry Role:
Join Date: Jul 2017
Posts: 31
|
I prefer to handover VPS Management company.To answer your question light speed would be better option but before that you need to check with mail platform and plugins used in it .
|
07-23-2017, 03:26 PM | #18 |
Confirmed User
Industry Role:
Join Date: Apr 2014
Posts: 385
|
Stupid question... better CentOS or Ubuntu server?
|
07-23-2017, 07:00 PM | #19 |
Confirmed User
Industry Role:
Join Date: Sep 2015
Posts: 88
|
Take Ubuntu, it will make everything easier for you (although CentOS isn't a bad choice)
|
07-24-2017, 12:14 AM | #20 |
Confirmed User
Industry Role:
Join Date: Apr 2014
Posts: 385
|
But what is best for performance, speed, etc?
If it is difficult, I learn, I have already used CentOS even without too many problems |
07-24-2017, 12:30 AM | #21 |
Confirmed User
Industry Role:
Join Date: Sep 2015
Posts: 88
|
So stay with what you know, it doesn't matter for your use, and these are solid OS.
What is your stack right now? |
07-24-2017, 07:31 AM | #22 |
It's 42
Industry Role:
Join Date: Jun 2010
Location: Global
Posts: 18,083
|
I agree -- it's a matter of the devil you know best.
|
07-24-2017, 02:41 PM | #23 |
Confirmed User
Industry Role:
Join Date: Apr 2014
Posts: 385
|
Ok, I want to try ubuntu with sentora (ex zpanel), just to begin with, then in case we change
|
07-24-2017, 04:39 PM | #24 |
Confirmed User
Industry Role:
Join Date: Apr 2014
Posts: 385
|
Aaaaand now that I created the droplet and I would be ready to install I have doubts about the panels...
I made a small list of what I use of cpanel and for what Actually, of cpanel the only buttons I use are:
Everything else I've practically never even looked at. On this server I think to put only 4-5 sites, very simple, need only PHP, MySQL, and cronjob to work Then some caches, eg. Memcache, varnish, Opcache, acpu, etc. I could use this https://www.digitalocean.com/communi...n-ubuntu-16-04 to put the server online This https://nixstats.com to monitor it PHP I think I use the 5.6, the subsequent I have always caused problems or loss of visits (but maybe it's my problem) I need a quick way to turn on/off errors and set E_ALL &-E_NOTICE, but I think it's always php.ini (Don't go very well with my URL rewriters, they create endless log files and they waste a lot of resources, so I turn it on and off every time I have to make some changes) For varnish and other chache I hope there are guides around... Mails don't need it I miss HTTPS, some sites use it, I have used let's encrypt, but I think he needs a panel, I also saw Autossl, but I did not use it, I have no idea how it works, suggestions? Surely, it seems little but it is very much, there will be many small things to configure install and manage, but I have taken a look at some guides and overall it does not seem impossible At this point I think I still keep a bit the shared server and start moving just a couple of sites (the one with a few visits) in the new droplet Digitalocean and start to make everything work, then if everything works keep moving sites, otherwise I change the DNS and I return to the shared server... (Hopefully not) Tips? Recommendations? Things I forgot? Problems that I will surely meet? Errors that everyone does at the beginning, to avoid? Every help and advice is greatly appreciated... thanks |
07-24-2017, 08:29 PM | #25 |
It's 42
Industry Role:
Join Date: Jun 2010
Location: Global
Posts: 18,083
|
MySQL
Code:
barry@paragon-DS-7:~$ mysql -u[username] -p Enter password: Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 13 Server version: 5.7.19-0ubuntu0.16.04.1 (Ubuntu) Copyright (c) 2000, 2017, Oracle and/or its affiliates. All rights reserved. Oracle is a registered trademark of Oracle Corporation and/or its affiliates. Other names may be trademarks of their respective owners. Type 'help;' or '\h' for help. Type '\c' to clear the current input statement. mysql> sudo apt install mycli barry@paragon-DS-7:~$ mycli -u[username] Password: Version: 1.5.2 Chat: https://gitter.im/dbcli/mycli Mail: https://groups.google.com/forum/#!forum/mycli-users Home: http://mycli.net Thanks to the contributor - Sudaraka Wijesinghe mysql username@localhost:(none)> [F2] Smart Completion: ON [F3] Multiline: OFF [F4] Emacs-mode Find your packages sudo apt search 'what you need' Code:
barry@paragon-DS-7:~$ sudo apt search php |grep -i 'php' https://github.com/rosehosting/nginx...nginx_vhost.sh Nginx HTTP server script https://www.google.com/search?num=10...+host+scr ipt Google is your friend Let's encrypt https://certbot.eff.org/docs/ good luck |
07-25-2017, 02:19 PM | #26 |
Confirmed User
Industry Role:
Join Date: May 2017
Location: California
Posts: 133
|
Both are great operating systems.
I have used both CentOS is very similar to Red Hat Enterprise and Ubuntu is based off of Debian. I enjoy working with Ubuntu a bit more than working with CentOS. In the end it comes down to personal preference. One of the main reasons I enjoy ubuntu better is because out of the box it comes with APT (Advanced Packaging Tool) library to perform installation and manage software. Where CentOS uses YUM. Both APT and YUM are great and pretty much do the same thing, but this is where it comes down to preference. I would rather type something like this to install mysql Code:
sudo apt-get install mysql-server Code:
sudo yum install mysql-server Its also worth noting that you can install APT on CentOS. |
07-25-2017, 02:23 PM | #27 | |
Confirmed User
Industry Role:
Join Date: May 2017
Location: California
Posts: 133
|
Quote:
You can install Apache, PHP, and MYSQL using tasksel... Code:
sudo apt-get install tasksel To install phpmyadmin use Code:
sudo apt-get install phpmyadmin |
|
07-25-2017, 03:56 PM | #28 |
Confirmed User
Industry Role:
Join Date: Apr 2014
Posts: 385
|
Thanks guys
I did the first step with Apache virtual host, now expect DNS propagation to see if everything works. (Hopefully well) Thanks for the support |
07-26-2017, 03:04 PM | #29 |
Confirmed User
Industry Role:
Join Date: Apr 2014
Posts: 385
|
Shit, something's not working.
I did not do much... installed virtual host, created 2 files and changed the DNS First this guide https://www.digitalocean.com/communi...n-ubuntu-16-04, an installation and a couple of files Then this Https://www.digitalocean.com/communi...h-digitalocean I changed the DNS on Namesilo and waited for it to propagate... Domains alternativegirlshardpics.com and transgender-hardpics.com It's been 24 hours and nothing seems to work. The 2 sites seem crazy, I expect to see those 2 stupid files "Welcome to Test.com!" instead sometimes "impossible to reach the site", ther times I see the old site, sometimes I see it without CSS... I can not understand if it is my PC, my browser, my connection or if there is really some error... How do you see my 2 sites? Did I get something wrong? |
07-27-2017, 12:44 AM | #30 |
It's 42
Industry Role:
Join Date: Jun 2010
Location: Global
Posts: 18,083
|
is that the right IP?
Code:
barry@paragon-DS-7:~$ dig any transgender-hardpics.com ; <<>> DiG 9.10.3-P4-Ubuntu <<>> any transgender-hardpics.com ;; global options: +cmd ;; Got answer: ;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 56212 ;; flags: qr rd ra; QUERY: 1, ANSWER: 5, AUTHORITY: 0, ADDITIONAL: 1 ;; OPT PSEUDOSECTION: ; EDNS: version: 0, flags:; udp: 512 ;; QUESTION SECTION: ;transgender-hardpics.com. IN ANY ;; ANSWER SECTION: transgender-hardpics.com. 1799 IN NS ns2.digitalocean.com. transgender-hardpics.com. 1799 IN NS ns3.digitalocean.com. transgender-hardpics.com. 1799 IN SOA ns1.digitalocean.com. hostmaster.transgender-hardpics.com. 1501023148 10800 3600 604800 1800 transgender-hardpics.com. 1799 IN NS ns1.digitalocean.com. transgender-hardpics.com. 3599 IN A 139.59.3.8 ;; Query time: 92 msec ;; SERVER: 127.0.0.1#53(127.0.0.1) ;; WHEN: Thu Jul 27 03:38:01 EDT 2017 ;; MSG SIZE rcvd: 183 barry@paragon-DS-7:~$ if the IP is right the apache web server is misconfigured or if you have a firewall HTTP 80 and HTTPS 443 is not open try server@root$ service ufw status try server@root$ service apache2 status |
07-27-2017, 04:46 PM | #31 |
Confirmed User
Industry Role:
Join Date: Apr 2014
Posts: 385
|
Code:
root@ubuntu-2gb-blr1-01:~# service ufw status ● ufw.service - Uncomplicated firewall Loaded: loaded (/lib/systemd/system/ufw.service; enabled; vendor preset: enabled) Active: active (exited) since Tue 2017-07-25 22:39:22 UTC; 2 days ago Main PID: 606 (code=exited, status=0/SUCCESS) Tasks: 0 Memory: 0B CPU: 0 CGroup: /system.slice/ufw.service Warning: Journal has been rotated since unit was started. Log output is incomplete or unavailable. service apache2 status ● apache2.service - LSB: Apache2 web server Loaded: loaded (/etc/init.d/apache2; bad; vendor preset: enabled) Drop-In: /lib/systemd/system/apache2.service.d └─apache2-systemd.conf Active: active (running) since Thu 2017-07-27 17:55:53 UTC; 5h 30min ago Docs: man:systemd-sysv-generator(8) Process: 22306 ExecStart=/etc/init.d/apache2 start (code=exited, status=0/SUCCESS) Tasks: 55 Memory: 6.3M CPU: 1min 40.510s CGroup: /system.slice/apache2.service ├─22323 /usr/sbin/apache2 -k start ├─22326 /usr/sbin/apache2 -k start └─22327 /usr/sbin/apache2 -k start Jul 27 17:55:51 ubuntu-2gb-blr1-01 systemd[1]: Starting LSB: Apache2 web server... Jul 27 17:55:51 ubuntu-2gb-blr1-01 apache2[22306]: * Starting Apache httpd web server apache2 Jul 27 17:55:52 ubuntu-2gb-blr1-01 apache2[22306]: AH00558: apache2: Could not reliably determine the server's fully qualified domain name, using 127.0.1.1. Set the 'ServerName' directive globally to suppress this message Jul 27 17:55:53 ubuntu-2gb-blr1-01 apache2[22306]: * Jul 27 17:55:53 ubuntu-2gb-blr1-01 systemd[1]: Started LSB: Apache2 web server. It makes you install a virtual host including the sample pages and does not let you open the firewall, as first step has a really demoral effect... First or later you think maybe it's better if I stop doing the programmer and I'm going to sell ice cream in Germany Looking for the errors reported by the commands that indicated me Barry-Xlovecam, I ended up on this https://www.digitalocean.com/communi...n-ubuntu-16-04 guide, which would be the next one I would have done, maybe it was better to do this first. I have configured the firewall and now it works Thank you very much for the help Now LAMP.... surely I'll be back for the next issue, probably caused by a guide stupid |
07-27-2017, 06:09 PM | #32 |
Confirmed User
Industry Role:
Join Date: Apr 2014
Posts: 385
|
OK, I installed MySQL and PHP without too many problems
I have not seen things like: Which version of PHP I installed (I would like 5.6), PFM or mariadb, etc... However, I came to the installation of the modules In the current VPS I have these The new server me from a list of installable http://porn-update.com/temp/php_modules.txt But something is missing, for example PDO... probably going to be installed separately My sites need just, php, mysql-pdo, cronjob, and some cache, no mail. But there are other modules that are extremely necessary to install that I don't know? |
07-27-2017, 09:00 PM | #33 | |
It's 42
Industry Role:
Join Date: Jun 2010
Location: Global
Posts: 18,083
|
open a ssh session
Code:
$ php -i|less Code:
$ php -i|more Quote:
I am using php 7.0 now you need to find these for your older version this is a good working start up install I found. Code:
$ sudo apt-get -y install php7.0-mysql php7.0-curl php7.0-gd php7.0-intl php-pear php-imagick php7.0-imap php7.0-mcrypt php-memcache php7.0-pspell php7.0-recode php7.0-sqlite3 php7.0-tidy php7.0-xmlrpc php7.0-xsl php7.0-mbstring php-gettext |
|
07-28-2017, 07:44 PM | #34 |
Confirmed User
Industry Role:
Join Date: Apr 2014
Posts: 385
|
Hi, in the list of this command php -i|less, PDO there, but does it mean it is already installed or that I can install it?
Code:
phpinfo() PHP Version => 7.0.18-0ubuntu0.16.04.1 System => Linux ubuntu-2gb-blr1-01 4.4.0-87-generic #110-Ubuntu SMP Tue Jul 18 12:55:35 UTC 2017 x86_64 Server API => Command Line Interface Virtual Directory Support => disabled Configuration File (php.ini) Path => /etc/php/7.0/cli Loaded Configuration File => /etc/php/7.0/cli/php.ini Scan this dir for additional .ini files => /etc/php/7.0/cli/conf.d Additional .ini files parsed => /etc/php/7.0/cli/conf.d/10-mysqlnd.ini, /etc/php/7.0/cli/conf.d/10-opcache.ini, /etc/php/7.0/cli/conf.d/10-pdo.ini, /etc/php/7.0/cli/conf.d/20-calendar.ini, /etc/php/7.0/cli/conf.d/20-ctype.ini, /etc/php/7.0/cli/conf.d/20-exif.ini, /etc/php/7.0/cli/conf.d/20-fileinfo.ini, /etc/php/7.0/cli/conf.d/20-ftp.ini, /etc/php/7.0/cli/conf.d/20-gettext.ini, /etc/php/7.0/cli/conf.d/20-iconv.ini, /etc/php/7.0/cli/conf.d/20-json.ini, /etc/php/7.0/cli/conf.d/20-mcrypt.ini, /etc/php/7.0/cli/conf.d/20-mysqli.ini, /etc/php/7.0/cli/conf.d/20-pdo_mysql.ini, /etc/php/7.0/cli/conf.d/20-phar.ini, /etc/php/7.0/cli/conf.d/20-posix.ini, /etc/php/7.0/cli/conf.d/20-readline.ini, /etc/php/7.0/cli/conf.d/20-shmop.ini, /etc/php/7.0/cli/conf.d/20-sockets.ini, /etc/php/7.0/cli/conf.d/20-sysvmsg.ini, /etc/php/7.0/cli/conf.d/20-sysvsem.ini, /etc/php/7.0/cli/conf.d/20-sysvshm.ini, /etc/php/7.0/cli/conf.d/20-tokenizer.ini PHP API => 20151012 PHP Extension => 20151012 Zend Extension => 320151012 Zend Extension Build => API320151012,NTS PHP Extension Build => API20151012,NTS Debug Build => no Thread Safety => disabled Zend Signal Handling => disabled Zend Memory Manager => enabled Zend Multibyte Support => disabled IPv6 Support => enabled DTrace Support => available, disabled Registered PHP Streams => https, ftps, compress.zlib, php, file, glob, data, http, ftp, phar Registered Stream Socket Transports => tcp, udp, unix, udg, ssl, tls, tlsv1.0, tlsv1.1, tlsv1.2 Registered Stream Filters => zlib.*, string.rot13, string.toupper, string.tolower, string.strip_tags, convert.*, consumed, dechunk, convert.iconv.*, mcrypt.*, mdecrypt.* This program makes use of the Zend Scripting Language Engine: Zend Engine v3.0.0, Copyright (c) 1998-2017 Zend Technologies with Zend OPcache v7.0.18-0ubuntu0.16.04.1, Copyright (c) 1999-2017, by Zend Technologies _______________________________________________________________________ Configuration : I have absolutely no idea why this thing happened... Can a downgrade of PHP create problems? Even if the server is new/empty Code:
sudo apt search php| egrep -i 'PDO|curl' WARNING: apt does not have a stable CLI interface. Use with caution in scripts. php-curl/xenial 1:7.0+35ubuntu6 all CURL module for PHP [default] php-phpdocumentor-reflection/xenial 1.0.7-1build1 all php-phpdocumentor-reflection-common/xenial 1.0-2build1 all Common reflection classes - phpDocumentor component php-phpdocumentor-reflection-docblock/xenial 2.0.4-1build1 all DocBlock parser - phpDocumentor component php-phpdocumentor-type-resolver/xenial 0.1.6-2 all TypeResolver and FqsenResolver - phpDocumentor component php7.0-curl/xenial-updates 7.0.18-0ubuntu0.16.04.1 amd64 CURL module for PHP phpdox/xenial 0.8.1.1-1ubuntu1 all python-sphinxcontrib.phpdomain/xenial 0.1.4-2 all Sphinx "phpdomain" extension |
07-28-2017, 07:57 PM | #35 | |
Masterbaiter
Industry Role:
Join Date: Aug 2016
Posts: 26,947
|
Quote:
__________________
Unlock the limitless potential of AI |
|
07-29-2017, 07:22 AM | #36 | |
Confirmed User
Industry Role:
Join Date: Jul 2017
Location: Worldwide
Posts: 37
|
Quote:
In practice there may be parts of your site that don't work well with one of the two versions, depending on for what version they were written. The differences between PHP5 and PHP7 may be the reason why you've experienced drop in traffic earlier. Something probably didn't work as it's supposed to but it went unnoticed. If you can confirm that your code works on both versions PHP7 is faster so I'd stick with it.
__________________
PUSHR CDN - High-performance content delivery network for fast growing projects Skype: Victor_NetStack |
|
07-29-2017, 06:04 PM | #37 |
It's 42
Industry Role:
Join Date: Jun 2010
Location: Global
Posts: 18,083
|
Code:
$ sudo apt-get -y install php7.0-mysql php7.0-curl php7.0-gd php7.0-intl php-pear php-imagick php7.0-imap php7.0-mcrypt php-memcache php7.0-pspell php7.0-recode php7.0-sqlite3 php7.0-tidy php7.0-xmlrpc php7.0-xsl php7.0-mbstring php-gettext php7.0-mysql was the fix, the rest looked useful to me so I installed them: gd, pear, imagemagic and sqlite3. I have needed to use these in the past and they were not installed. My HTTP server is Nginx and PHP will work out of the box with a tweak to the gateway For reference: Fix Nginx PHP gateway -- if anyone else is struggling with this ... Code:
location ~ \.php { fastcgi_index index.php; fastcgi_split_path_info ^(.+\.php)(.*)$; include /etc/nginx/fastcgi_params; fastcgi_pass 127.0.0.1:[port number]; fastcgi_param SCRIPT_FILENAME \$document_root\$fastcgi_script_name; } Code:
root@localhost:/etc/php/7.0/fpm/pool.d# egrep 'listen' www.conf ; - 'listen' (unixsocket) ; 'ip.add.re.ss:port' - to listen on a TCP socket to a specific IPv4 address on ; '[ip:6:addr:ess]:port' - to listen on a TCP socket to a specific IPv6 address on ; 'port' - to listen on a TCP socket to all addresses ; '/path/to/unix/socket' - to listen on a unix socket. change>>>>listen = /run/php/php7.0-fpm.sock to>>> listen = 127.0.0.1:[same port number used in your Nginx configuration files] ^^^^^ ; Set listen(2) backlog. ;listen.backlog = 511 service php7.0-fpm restart |
07-30-2017, 04:40 AM | #38 |
Confirmed User
Industry Role:
Join Date: Apr 2014
Posts: 385
|
My sites works with 7, the code structure of my sites is very simple, I have basically just updated all queries from mysql to pdo
|
07-31-2017, 10:04 AM | #39 |
Confirmed User
Industry Role:
Join Date: Apr 2014
Posts: 385
|
So I did a few things... I did the PHP downgrade with this:
Code:
From php5.6 to php7.0: Apache: sudo a2dismod php5.6 ; sudo a2enmod php7.0 ; sudo service apache2 restart CLI: sudo update-alternatives --set php /usr/bin/php7.0 From php7.0 to php5.6: Apache: sudo a2dismod php7.0 ; sudo a2enmod php5.6 ; sudo service apache2 restart CLI: sudo update-alternatives --set php /usr/bin/php5.6 But it does not work almost anything... PHP does not seem to work, I put 2 files in the root, index.php and Info.php (phpinfo), return 2 pages blank... looking at the source code you see the PHP code... By visiting https:alternativegirlshardpics.com, it says invalid certificate Shit, it happened some mess... you think I can fix it? Even when I install modules I'm not sure about installing them on PHP 5.6 or 7 I almost thought about making a new droplet and install directly only PHP 5.6 Then I noticed that the folder structure is domain1.com/public_html Domain2.com/public_html I would like to public_html/domain1. com public_html/domain2. com Just change the addresses of the files on VirtualHost? |
07-31-2017, 04:26 PM | #40 |
It's 42
Industry Role:
Join Date: Jun 2010
Location: Global
Posts: 18,083
|
If the PHP 7 was working why mess with it?
It was working in HTTP or in cli only (terminal) As far as your paths; You need to add 80,443 and what is needed for TLS (SSL HTTPS) Code:
<VirtualHost *> ServerAdmin [email protected] ServerName example.com ServerAlias www.example.com # Indexes + Directory Root. DirectoryIndex index.html index.shtml index.php index.cgi index.xhtml DocumentRoot /home/[your path]/public_html # CGI Directory ScriptAlias /cgi-bin/ /home/[your path]/public_html <Location /cgi-bin> Options +ExecCGI AddHandler server-parsed .shtml .xhtml </Location> #rewrites RewriteEngine on # Logfiles ErrorLog /home/[your path]/logs/error.log CustomLog /home/[your path]/logs/access.log combined <IfModule security2_module> SecRuleEngine Off </IfModule> <Directory /home/[your path]/public_html> Order allow,deny Allow from all # New directive needed in Apache 2.4.3: Require all granted </Directory> #IMPORTANT TO ADD^^^! </VirtualHost> #a2ensite example.com #/etc/init.d/apache2 restart |
08-01-2017, 09:02 AM | #41 |
Confirmed User
Industry Role:
Join Date: Apr 2014
Posts: 385
|
But where?
I have this: sudo nano /etc/apache2/sites-available/alternativegirlshardpics.com.conf and this: sudo nano /etc/apache2/mods-enabled/dir.conf |
08-01-2017, 12:18 PM | #42 |
Confirmed User
Industry Role:
Join Date: Apr 2014
Posts: 385
|
And then suddenly a lighting...
is there anything in the PHP configuration that does not work <? But it requires this <?php, probably not active |
08-01-2017, 05:27 PM | #43 | |
It's 42
Industry Role:
Join Date: Jun 2010
Location: Global
Posts: 18,083
|
Quote:
$cd /etc/apache2/sites-available $ls -1 [see what is there] $cp alternativegirlshardpics.com.conf alternativegirlshardpics.com.conf~ [back up your file that works] nano /etc/apache2/sites-available/alternativegirlshardpics.com.conf [make your edits] ^X 'y' $a2ensite alternativegirlshardpics.com.conf $ /etc/init.d/apache2 restart or; service apache2 restart php is always starts 5 and 7 (4 was <? as I recall) <?php '{......}' ?> in php 7 you actually don't need the closing tag -- try it LOL works ... check your return on this Code:
barry@paragon-DS-7:~$ apt search apache2|grep 'php' WARNING: apt does not have a stable CLI interface. Use with caution in scripts. libapache2-mod-php/xenial,xenial 1:7.0+35ubuntu6 all libapache2-mod-php7.0/xenial-updates 7.0.18-0ubuntu0.16.04.1 amd64 php7.0-fpm/xenial-updates,now 7.0.18-0ubuntu0.16.04.1 amd64 [installed,automatic] barry@paragon-DS-7:~$ |
|
08-02-2017, 10:54 AM | #44 |
Confirmed User
Industry Role:
Join Date: Apr 2014
Posts: 385
|
Thank you
Almost online, in the end I thought I'd install an 14.04 with PHP5 native, then later with calm install a 16.04 with PHP 7. And I will manage the whole changing DNS There are almost, the databases are online, the files are online, only one last thing is missing, the symlink. My sites to work need to symlink to a folder that contains functions shared by all. Usually on VPS with cpanel I created the symlink by creating a file with this code and loading it into public_html. Code:
symlink('/home/pornupda/public_html/function_global', '/home/pornupda/public_html/transgender-hardpics.com/function_global'); I have these /var/www/html/ /var/www/public_html/ In /html responds the server IP, in public_html my sites (following the tutorial has happened this) In public_html: Alternativegirlshardpics.com Function_global Transgender-hardpics.com I tried to create the symlink with this code Code:
symlink('/var/www/public_html/function_global', '/var/www/public_html/alternativegirlshardpics.com/function_global'); But he says Code:
Warning: symlink (): Permission denied in/var/www/html/add_symlink_digitalocean.php on line 3 Can I change /html in /public_html? is a mess happening? Better rather if I move my sites from /public_html to /html? Just to put a little in order... |
08-02-2017, 12:54 PM | #45 |
Confirmed User
Industry Role:
Join Date: Apr 2014
Posts: 385
|
Found
From terminal Code:
ln -s path/to/source path/destination/symlink |
08-02-2017, 12:56 PM | #46 |
It's 42
Industry Role:
Join Date: Jun 2010
Location: Global
Posts: 18,083
|
I make my document root for the server permissions
username:www-data user:group the command is from the level above the directory whose permissions you want to change Code:
$ stat 'the directory name' #return the ownership info, *check any sub-directories and files too. $ stat * #everything below the target #then if necessary $ chown -R username:www-data #recursively change ownership permissions #you need root or sudo also to FTP into the ..../html owner 0 root if html/mydocroot is username:www-data and there is a symbolic link ... I use scp at the command line or sftp in a FTP client -- then you need no FTP server, its all over ssh -- more secure and less resources used. the symbolic link may not work due to a permissions conflict? ** ln -s yeah .... |
08-02-2017, 01:59 PM | #47 |
Confirmed User
Industry Role:
Join Date: Apr 2014
Posts: 385
|
Sites Online!
But nothing works... Only the HTTPS version works https://www.alternativegirlshardpics.com/ Without HTTPS Code:
Internal server Error Apache/2.4.7 (Ubuntu) server at www.alternativegirlshardpics.com Port 80 Code:
< img src = "https://www.alternativegirlshardpics.com/images/blank.gif" data-src = "https://images03-fame.gammacdn.com/movies/64703/64703_01/previews/2/174/top_1_185x135/64703_01_01.jpg" https://www.alternativegirlshardpics.com/1004 It seems a problem URL rewriter, but on port 443 ??? Seems like an SSL problem. In both sites I have added a certificate let's encrypt, following this guide https://www.digitalocean.com/communi...n-ubuntu-14-04 What's missing??? I'll attach the various virtual host files because I'm not understanding anything anymore /etc/apache2/sites-enabled/000-default.conf Code:
<VirtualHost *:80> # The ServerName directive sets the request scheme, hostname and port that # the server uses to identify itself. This is used when creating # redirection URLs. In the context of virtual hosts, the ServerName # specifies what hostname must appear in the request's Host: header to # match this virtual host. For the default virtual host (this file) this # value is not decisive as it is used as a last resort host regardless. # However, you must set it for any further virtual host explicitly. #ServerName www.example.com ServerAdmin [email protected] DocumentRoot /var/www/public_html <Directory /var/www/public_html> Options Indexes FollowSymLinks MultiViews AllowOverride All Order allow,deny allow from all # New directive needed in Apache 2.4.3: Require all granted </Directory> # Available loglevels: trace8, ..., trace1, debug, info, notice, warn, # error, crit, alert, emerg. # It is also possible to configure the loglevel for particular # modules, e.g. #LogLevel info ssl:warn ErrorLog ${APACHE_LOG_DIR}/error.log CustomLog ${APACHE_LOG_DIR}/access.log combined # For most configuration files from conf-available/, which are # enabled or disabled at a global level, it is possible to # include a line for only one particular virtual host. For example the # following line enables the CGI configuration for this host only # after it has been globally disabled with "a2disconf". #Include conf-available/serve-cgi-bin.conf </VirtualHost> Code:
<VirtualHost *:80> # The ServerName directive sets the request scheme, hostname and port that # the server uses to identify itself. This is used when creating # redirection URLs. In the context of virtual hosts, the ServerName # specifies what hostname must appear in the request's Host: header to # match this virtual host. For the default virtual host (this file) this # value is not decisive as it is used as a last resort host regardless. # However, you must set it for any further virtual host explicitly. #ServerName www.example.com ServerAdmin [email protected] ServerName alternativegirlshardpics.com ServerAlias www.alternativegirlshardpics.com DocumentRoot /var/www/public_html/alternativegirlshardpics.com # CGI Directory ScriptAlias /cgi-bin/ /var/www/public_html/alternativegirlshardpics.com <Location /cgi-bin> Options +ExecCGI AddHandler server-parsed .shtml .xhtml </Location> #rewrites RewriteEngine on <IfModule security2_module> SecRuleEngine Off </IfModule> <Directory /var/www/public_html/alternativegirlshardpics.com> Options Indexes FollowSymLinks MultiViews AllowOverride All Order allow,deny allow from all # New directive needed in Apache 2.4.3: Require all granted </Directory> # Available loglevels: trace8, ..., trace1, debug, info, notice, warn, # error, crit, alert, emerg. # It is also possible to configure the loglevel for particular # modules, e.g. #LogLevel info ssl:warn ErrorLog ${APACHE_LOG_DIR}/error.log CustomLog ${APACHE_LOG_DIR}/access.log combined /etc/apache2/sites-available/alternativegirlshardpics.com-le-ssl.conf Code:
<IfModule mod_ssl.c> <VirtualHost *:443> # The ServerName directive sets the request scheme, hostname and port that # the server uses to identify itself. This is used when creating # redirection URLs. In the context of virtual hosts, the ServerName # specifies what hostname must appear in the request's Host: header to # match this virtual host. For the default virtual host (this file) this # value is not decisive as it is used as a last resort host regardless. # However, you must set it for any further virtual host explicitly. #ServerName www.example.com ServerAdmin [email protected] ServerName alternativegirlshardpics.com ServerAlias www.alternativegirlshardpics.com DocumentRoot /var/www/public_html/alternativegirlshardpics.com # Available loglevels: trace8, ..., trace1, debug, info, notice, warn, # error, crit, alert, emerg. # It is also possible to configure the loglevel for particular # modules, e.g. #LogLevel info ssl:warn ErrorLog ${APACHE_LOG_DIR}/error.log CustomLog ${APACHE_LOG_DIR}/access.log combined # For most configuration files from conf-available/, which are # enabled or disabled at a global level, it is possible to # include a line for only one particular virtual host. For example the # following line enables the CGI configuration for this host only # after it has been globally disabled with "a2disconf". #Include conf-available/serve-cgi-bin.conf SSLCertificateFile /etc/letsencrypt/live/alternativegirlshardpics.com/cert.pem SSLCertificateKeyFile /etc/letsencrypt/live/alternativegirlshardpics.com/privkey.pem Include /etc/letsencrypt/options-ssl-apache.conf SSLCertificateChainFile /etc/letsencrypt/live/alternativegirlshardpics.com/chain.pem </VirtualHost> </IfModule> <IfModule mod_ssl.c> <VirtualHost *:443> # The ServerName directive sets the request scheme, hostname and port that # the server uses to identify itself. This is used when creating # redirection URLs. In the context of virtual hosts, the ServerName # specifies what hostname must appear in the request's Host: header to # match this virtual host. For the default virtual host (this file) this # value is not decisive as it is used as a last resort host regardless. # However, you must set it for any further virtual host explicitly. #ServerName www.example.com ServerAdmin [email protected] ServerName alternativegirlshardpics.com ServerAlias www.alternativegirlshardpics.com DocumentRoot /var/www/public_html/alternativegirlshardpics.com # Available loglevels: trace8, ..., trace1, debug, info, notice, warn, # error, crit, alert, emerg. # It is also possible to configure the loglevel for particular # modules, e.g. #LogLevel info ssl:warn ErrorLog ${APACHE_LOG_DIR}/error.log CustomLog ${APACHE_LOG_DIR}/access.log combined # For most configuration files from conf-available/, which are # enabled or disabled at a global level, it is possible to # include a line for only one particular virtual host. For example the # following line enables the CGI configuration for this host only # after it has been globally disabled with "a2disconf". #Include conf-available/serve-cgi-bin.conf SSLCertificateFile /etc/letsencrypt/live/alternativegirlshardpics.com/cert.pem SSLCertificateKeyFile /etc/letsencrypt/live/alternativegirlshardpics.com/privkey.pem Include /etc/letsencrypt/options-ssl-apache.conf SSLCertificateChainFile /etc/letsencrypt/live/alternativegirlshardpics.com/chain.pem </VirtualHost> </IfModule> Code:
[Wed Aug 02 21:11:14.880693 2017] [ssl:warn] [pid 1306] AH02292: Init: Name-based SSL virtual hosts only work for clients with TLS server name indication support (RFC 4366) [Wed Aug 02 21:11:15.275079 2017] [ssl:warn] [pid 1307] AH02292: Init: Name-based SSL virtual hosts only work for clients with TLS server name indication support (RFC 4366) [Wed Aug 02 21:11:15.284878 2017] [mpm_prefork:notice] [pid 1307] AH00163: Apache/2.4.7 (Ubuntu) PHP/5.5.9-1ubuntu4.21 OpenSSL/1.0.1f configured -- resuming normal operations [Wed Aug 02 21:11:15.284941 2017] [core:notice] [pid 1307] AH00094: Command line: '/usr/sbin/apache2' [Wed Aug 02 21:12:44.308475 2017] [core:alert] [pid 1318] [client 66.249.66.205:38269] /var/www/public_html/transgender-hardpics.com/.htaccess: Invalid command 'Header', perhaps misspelled or defined by a module not included in the server configuration |
08-04-2017, 02:22 PM | #48 |
Confirmed User
Industry Role:
Join Date: Apr 2014
Posts: 385
|
Meanwhile I created another droplet and started it all over again, and it worked...
The 2 sites are online, it works url_rewriter and I solved the problem of the photos (my fault, uploaded an old file without a JavaScript) The only thing I haven't reinstalled is let's encrypt, so my sites now only work in http So I think it's been let's encrypt to make the mess... I would not repeat everything, so I'm thinking about another way to make HTTPS, suggestions? P.S. How do I know if Opcache, memcached and APCU, etc. are working? Last stupid question: varnish does not work in HTTPS? Should I use Nginx for HTTPS? |
08-07-2017, 05:13 PM | #49 |
Confirmed User
Industry Role:
Join Date: Apr 2014
Posts: 385
|
Sites Online!
I destroyed and created a hundred droplet in the meantime, but we finally got to have the 2 sites online with working HTTPS https://www.alternativegirlshardpics.com/ https://www.transgender-hardpics.com/ I tried to install varnish with Apache and Nginx, but it was like throwing a firecracker inside the server case, nothing worked anymore and there was no way to understand why... The guides seem kinda old, maybe varnish is dead with https... ??? Anyway we are online, now optimization... cache, gzip compression, monitoring etc etc etc, tips? |
08-07-2017, 08:56 PM | #50 |
It's 42
Industry Role:
Join Date: Jun 2010
Location: Global
Posts: 18,083
|
You are hotlinking to images that are not using TLS(HTPS)
So, your SSL is broken -- not your fault -- but is broken HTTPS better than no HTTPS? |