![]() |
But where?
I have this: sudo nano /etc/apache2/sites-available/alternativegirlshardpics.com.conf and this: sudo nano /etc/apache2/mods-enabled/dir.conf |
And then suddenly a lighting...
is there anything in the PHP configuration that does not work <? But it requires this <?php, probably not active |
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' |
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... |
Found :thumbsup
From terminal Code:
ln -s path/to/source path/destination/symlink |
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' 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 .... |
Sites Online! :)
But nothing works... :Oh crap Only the HTTPS version works https://www.alternativegirlshardpics.com/ Without HTTPS Code:
Internal server Error 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> Code:
<VirtualHost *:80> /etc/apache2/sites-available/alternativegirlshardpics.com-le-ssl.conf Code:
<IfModule mod_ssl.c> 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) |
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? |
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? |
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? |
Honestly to me the https make just crap, I find them an extremely stupid thing, especially on sites like these, but slowly everyone is getting scared by big G.
At the logical level on many occasions have no meaning, eg in cases like mine where the site is HTTPS but the contents are not. I think it's just an advantage for big G that certainly somehow manages to simplify or reduce the weight of the pages that he has to read. The fact that they should be used only in login procedures or containing sensitive data has been completely suppressed by the fear of not complying with the rule of big G, so many sites apply them on all pages. At the moment they almost seem to be the main factor even just to be taken into account by big G, also I do not think it is absolutely true. With regard to end users I believe that 99% have absolutely no idea what the HTTPS protocol is, nor do they care about it. My sites would not absolutely need it, I'm installing them only in some, just not to be the only idiot not to have them, but I would gladly do it less. |
Another stupid question...
Cloudflare needs something on the server to work? I use it only in a bigboobshardpics.com site and only in the Cdn folder, where all the images of the site are located. http://porn-update.com/temp/Schermat...2017:53:43.png The site itself does not need cloudflare, slows down if I apply it to the whole site. The idea is to create a kind of CDN leveraging CloudFlare, just for images. Does it make sense to you? Need something on the server for CloudFlare? |
And so, I've seen everything, tried everything, done everything...
The 2 sites are online: https://www.alternativegirlshardpics.com/ https://www.transgender-hardpics.com/ I have: Installed LAMP Configured Virtual Host Configured DNS on Digitalocean Installed phpMyAdmin Created MySQL database and users Modified the configuration of php.ini Created Symlink Open the ports on the firewall Enabled Mod_rewriter Enabled Mod_deflate Install let's encrypt and certificates Enabled Opcache Installed and enabled memcached Installed and enabled cache/Chace_disk and created some cronjob And in a couple of weeks it doesn't look bad... I'm at the point where I would see the 2 sites run for a few days and if all goes well start transferring to this server some other site But I wonder, how many things will I have forgotten or ignored? For example, now I have php 5.5.9, maybe it is worth switching to 5.6? (at 7 in ubuntu 16.04 I will pass in the future with another droplet) I have not installed mod security, but he has always been obnoxious to me, but maybe better to install it? I was unable to install varnish (it happened a mess), will it be worth losing more time or not? I'm not sure it works gzip compression, but deflate is installed and configured, do I have to do anything else? I tried to configure if-modified-since, but I did not understand if it worked...:( Will miss something important? phpinfo() |
How To Set Up a Firewall with UFW on Ubuntu 16.04
https://www.digitalocean.com/communi...n-ubuntu-16-04 Shields up -- tighten your ship up. If you have a static ip set that for ssh and mysql remote -- use sftp over port 22 |
Thank you
Maybe I missed something in the configuration of url_rewriter, because this stupid rule RewriteRule tags/ tags.php [L] does not work https://www.alternativegirlshardpics.com/tags/ It always worked, but on the new server does not want to work... I tried to rewrite it in 1000 different ways, RewriteRule ^tags$ tags.php [L] RewriteRule ^tags\/$ tags.php [L] But it just doesn't work I searched in Digitalocean and Google, but I do not find particular configurations of url_rewriter It is not a basic page, I can directly use tags.php, but I would like to understand why it does not work... Any ideas? P.S. of all that could go wrong, if this is the only thing that does not work, I feel more than lucky... :thumbsup |
using .htaccess in Apache2 right
check $stat .htaccess the file permission might need to be user:www-data (user:group) if PHP needs to use that file. |
is root...:mad:
http://porn-update.com/temp/Schermat...2021:47:22.png Code:
root@ubuntu-2gb-blr1-14-04-3:/var/www/html/alternativegirlshardpics.com# stat .htaccess |
Another stupid question
For cronjob I use: crontab -e And this line of code 0 16 * * * /usr/bin/php /var/www/html/alternativegirlshardpics.com/cronojob.php But I'm not sure do something... They are active for a few days, but I do not receive mail and I see no changes in the site (the Cronjob upload new content, but may be there are no new content these days) The scripts have an output that I would like to receive via mail, but I did not understand if I have to set the mail for the cronjob somewhere... I don't know if they're working.... How can I understand? Are there any logs anywhere? Something missing in my code? In the different servers sometimes make me add -p, -f etc. But I never understood what they serve... and I have not found guides that explain it... |
Quote:
for cronjob - don't run cron on root this is a important issue and I strong recommend using some service like "https://www.webcron.org/" where u can get a mail confirmation or stats/logs and you don't need to know magic it skills - basically about a webcron I use since 2009 when I load 10 euros and i have 2 left. Is a fucking cheap and save your time, keep your server clean and safe and easy access via page from mobile, no need to login via ssh to check fix or stop. tnx |
I do not want to use a paid service... I have a Linux server, the server must operate the Cronjob...
|
Quote:
|
try this
Quote:
sometimes you have to cd then use the cli always end you cron with a new line You need a MTA and Email server to send an email out. see cd /var/logs to troubleshoot cron Code:
root~:$ cat /var/logs/syslog|less |
Quote:
I don't need any more mail, just the ones with the result of the cronjob. The cronjob logs are weird, I can't figure out if it works. Code:
Aug 12 06:39:01 ubuntu-2gb-blr1-14-04-3 CRON[11065]: (root) CMD ( [ -x /usr/lib/php5/maxlifetime ] && [ -x /usr/lib/php5/sessionclean ] && [ -d /var/lib/php5 ] && /usr/lib/php5/sessionclean /var/lib/php5 $(/usr/lib/php5/maxlifetime)) I have search the error in Google, but the answers are all very confusing... |
Quote:
|
Did you edit the conrab to a
(cd /path/; php file.php) try it manually does the cron work manually? maybe without the \. that is from an old php 5 install? or just php /path/file.php su 'user' password ******** crontab -e make a user crontab for this then verify $ stat [] that any file to be written to is permissions user:www-data otherwise the php will not be able to write to the file you could go up from 644 to 666 and try it also If it is a PDO MySQL make sure you settings are correct for the database make sure there is a \n (newline) at the end of the command leave the > /dev/null 2>&1 off for now I don't see it working Is there some file affected -- can you stat a date time? Mail servers are a hassle to set up correctly -- why do you really need an email -- to feel good? Can't you tell by the website's updates if the cronjob is working? |
Varnish doesn't work (yet) with Apache https. You have to use Nginx to handle incoming SSL requests:
nginx (https, 443) -> varnish (http, 80) -> apache (http, 8080) See here for more details. For just sending mails you can use mailx (a Unix utility program for sending and receiving mail,) command, no locale MTA is required (like Postfix) and use the Gmail MTA. If you don't have the mailx command, you can install the package. You can use this command to send emails: echo -e "your body text" | mailx -v -s "subject text" \ -S smtp-use-starttls \ -S ssl-verify=ignore \ -S smtp-auth=login \ -S smtp=smtp://smtp.gmail.com:587 \ -S from="[email protected]" \ -S [email protected] \ -S smtp-auth-password=yourGmailpasswd \ -S ssl-verify=ignore recipientemailaddress copy this command to a file (shell script) and make it executable. With cron it is easy to execute this script to run periodically at fixed times. and never, ever use ftp. Use sftp(secure ftp)or rsync to transfer data to your server. Ftp is unsecure and all the data is unencrypted. Learn shell commands and to test things and learn things install Ubuntu or Centos. on your local pc. Copy (with rsync) all the data to your local pc (open port 22 for local ssh server) so you can test things. |
Thanks for the answers.
The Cronjob, manually launched works (and works on other servers) I added a file https://www.alternativegirlshardpics.com/lastcron.txt the timestamp of the last started. fwrite in cronojob.php. Now I've added all the possible ways, to figure out if someone works, then if it works I'll see what it is http://porn-update.com/temp/Schermat...2018-50-40.png The mail I really would need, because I load data from RSS, XML, TXT files etc that are not mine and every day there is some new error to correct and fix. Via Mail I also get the output of PHP errors. |
no: cd /usr/share//../../ is an example path
the way it works, is the cron will cd to that location ; (<stop next command) php ./(execute this file) then you need no path to the file try that manually as the cron would do it $ cd /var/www/html/alternativegirlshardpics.com/; php ./cronojob.php see if it works ok in a bash shell (ssh) and NOT a browser so Code:
0 16 * * * (cd /var/www/html/alternativegirlshardpics.com/; php ./cronojob.php) |
I tried everything, done everything,
I also tried to use different users, both root and normal user Nothing ever works. But in the logs I found this Code:
Aug 16 20:10:01 ubuntu-2gb-blr1-14-04-3 CRON[1520]: (root) CMD (php /var/www/html/alternativegirlshardpics.com/cronojob.php) However, the mails of the cronjob I need... |
https://serverfault.com/questions/13...tput-to-syslog
try these ideas setting up a 'proper' email server is not just installing postfix. You will need to create a database, install an MTA setup like Dovecot and an email daemon. You will need to shell into mysql to create email accounts in a the database or find a web GUI to do this. Try the idea in that link first. Try Code:
$ sudo apt-get install libxml2-utils |
As i said, use mailx and Gmail MTA. Easy for just sending emails.
btw, Postfix does not need MySql and Dovecot. Just use your login account. If you only want to send out emails Dovecot is not needed either. Dovecot is an IMAP and POP3 email server (for receiving emails). But again, you don't need a local MTA . |
So for now I have installed postfix and added the MAILTO= parameter in my crontab, and the mails come to me, so I think Cronjob started to work.
And for me it would be enough already., now calmly I see to understand the rest of your indications The problem I have now is that I do not get the output of the file via mail, but the code of the file... I mean line by line all the PHP code of my file cronjob.php via mail... ??? And the test file https://www.alternativegirlshardpics.com/lastcron.txt still does not exist, I think PHP does not run... but why??? :helpme Quote:
|
Quote:
Complicated set up. Keep it simple open the file in a browser? put the file in in a web root. or copy it there as part of the cron. Or, cron a daily scp command on your local computer if you have a LINUX box to use locally. I don't understand why you have this bad code issue in the cron -- I would fix that problem programatically or find another feed source ... |
So... curl works...
But I'm not happy... I want to know why this damned crontab does not run my PHP scripts and I will not be happy until I can find out... Postfix gave me some problems with the aliases etc, and fills me the logs of rubbish... Initially the mails started to arrive, then I restarted the server and postfix started to create problems, I took it half an hour to be able to have the mail again... Maybe it was enough to add the parameter MAILTO on crontab and maybe the mails arrived the same... Anyway, for now curl and if everything works in a few days start to move here some sites |
Is normal all this junk in my syslog?
Code:
Aug 18 06:41:49 ubuntu-2gb-blr1-14-04-3 rsyslogd: [origin software="rsyslogd" swVersion="7.4.4" x-pid="918" x-info="http://www.rsyslog.com"] rsyslogd was HUPed Other thing, page scan times... Long ago when the server worked fine 200-250 milliseconds, now with new server 1100-1200 milliseconds (so much), can I do something? http://porn-update.com/temp/Schermat...2022-11-49.png http://porn-update.com/temp/Schermat...2022-12-15.png Will it improve in the future? Maybe cache or server that optimizes? |
S**t, today I almost thought about starting to move some site... and I found this...
Code:
Cron <root@ubuntu-2gb-blr1-14-04-3> curl https://www.alternativegirlshardpics.com/cronojob.php This is syslog... there are always a lot of strange lines... which I'm not sure there should be... Code:
Aug 21 15:09:01 ubuntu-2gb-blr1-14-04-3 CRON[23886]: (root) CMD ( [ -x /usr/lib/php5/maxlifetime ] && [ -x /usr/lib/php5/sessionclean ] && [ -d /var/lib/php5 ] && /usr/l |
Code:
curl "https://www.alternativegirlshardpics.com/cronojob.php" '____' works in a bash terminal (or ssh) ONLY |
Today it works, only yesterday did that thing... I would like to understand why before starting to move sites with many more visits
All that junk in the syslogs is normal? Or something or someone is killing me the server? I don't need cron hourly, can I take it off? |
Another thing, I was thinking about varnish...
Not all my sites are HTTPS, can I install varnish? Only for HTTP, even if it does not do HTTPS maybe does something But can varnish and HTTPS coexist? Varnish only works on port 80 or if installed can create problems with the 443 of HTTPS? |
How should I read this?
http://porn-update.com/temp/Schermat...2000-04-42.png Am I already at the limit? Or do I have many other unused resources? I have too much cache? It is strange this graph, free is very small, but also used is very small, cached is a lot, buffered seems growing but free and used do not seem to shrink... I'm kinda confused??? Can someone help me understand? |
All times are GMT -7. The time now is 02:51 PM. |
Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
©2000-, AI Media Network Inc