Posts

Showing posts from July, 2022

LookupError Exception

 add sleep time LookupError Exception is the Base class for errors raised when something can't be found . 

Youtube autoplay not working on mobile devices with embedded HTML5 player

 <!DOCTYPE html> <html>     <head>         <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=2.0, minimum-scale=1.0, user-scalable=yes">     </head>   <body> <!-- 1. The <iframe> (video player) will replace this <div> tag. --> <div id="player"></div> <script>   // 2. This code loads the IFrame Player API code asynchronously.   var tag = document.createElement('script');   tag.src = "https://www.youtube.com/iframe_api";   var firstScriptTag = document.getElementsByTagName('script')[0];   firstScriptTag.parentNode.insertBefore(tag, firstScriptTag);   // 3. This function creates an <iframe> (and YouTube player)   //    after the API code downloads.   var player;   function onYouTubeIframeAPIReady() {     player = new YT.Player('player', {       width: '100%',       videoId: 'rsDY659XAA8',       playe

How to rsync over ssh when directory names have spaces

 50 20 21 7 * /bin/sh /mnt/sdf1/backup/backupnew.sh #!/bin/bash rsync --protect-args -avzhPe 'ssh -p 1666' "root@49.248.142.90:/home/PNGSCloud 2012 to 31032022" /mnt/sdf1/public_html/  &> /mnt/sdf1/backup/logsnew.log  --protect-args  and "" from root 

PNG virus mail

 zip all attached documnets 

How To Secure Apache with Let's Encrypt on Ubuntu

  Step 1 — Installing Certbot To obtain an SSL certificate with Let’s Encrypt, you need to install the Certbot software on your server. For this tutorial, we’ll usethe default Ubuntu package repositories to install Certbot. Run the following command, which will install two packages:  certbot  and  python3-certbot-apache . The latter is a plugin that integrates Certbot with Apache, so that it’s possible to automate obtaining a certificate and configuring HTTPS within your web server with a single command: sudo apt install certbot python3-certbot-apache Copy Confirm installation by pressing  Y  and then  ENTER  to accept. Certbot is now installed on your server. Next, you’ll verify Apache’s configuration to make sure your virtual host is set appropriately. This ensures that the  certbot  client script will be able to detect your domains and reconfigure your web server to use your newly generated SSL certificate automatically. Step 4 — Obtaining an SSL Certificate Certbot provides a va

By default, Apache will listen on all IPs, both IPv6 and IPv4.

  To turn off IPv6 in Apache, just change the Listen directive to: in apache.conf Listen 0.0.0.0:80 Listen 0.0.0.0:443

rank math sitemap 404

 just save permalink once without making any changes and purge all caches

outgoing internet was not working plesk ping not working

 https://51.195.88.114:8443/plesk/modules/firewall/ Disable  Firewall Rules Management

504 gateway time-out nginx plesk

Image
 site was having virus https://nikosantoniadis.tv/bum.php after renaming plugin folder got site working

server not accessible

all this can be done from rescue mode   1.disk 2./etc/sysconfig/network-scripts  3.flush iptables in etc/rc/local /sbin/iptbles -F 4. change kernel  [root@plskcp network-scripts]# cat ifcfg-eth0 BOOTPROTO=none DEFROUTE=yes DEVICE=eth0 GATEWAY=51.195.88.254 HWADDR=a0:42:3f:46:ef:82 IPADDR=51.195.88.114 NETMASK=255.255.255.0 ONBOOT=yes TYPE=Ethernet USERCTL=no with IPv6  BOOTPROTO=none DEFROUTE=yes DEVICE=eth0 GATEWAY=213.136.81.1 HWADDR=00:50:56:44:fc:33 IPADDR=213.136.81.82 IPV6ADDR=2a02:c207:2078:0211:0000:0000:0000:0001/64 IPV6INIT=yes IPV6_AUTOCONF=no IPV6_DEFAULTGW=fe80::1 IPV6_FORCE_ACCEPT_RA=no NETMASK=255.255.255.0 ONBOOT=yes TYPE=Ethernet server Ip was different so check with ip a and confirm

How to fix rsync host key verification failed

 rsync -avhe 'ssh -p 22 -o StrictHostKeyChecking=no' * ssh -p 22 root@213.136.81.82:/mnt Alternate Fixes Apart from the major reasons mentioned above, some other reasons like using the wrong hostname/IP address can also trigger this error. The fix here would be to double-check the IP address or hostname used for the connection. Alternatively, this error can be fixed by disabling the host key check with rsync. This can be done by appending the parameter “ssh -o StrictHostKeyChecking=no” with the  rsync command .

Problem 1: package plesk-php74-imagick-3.7.0-0redhat.8.220616.1430.x86_64 requires libMagickCore-6.Q16.so.6()(64bit), but none of the providers can be installed

 Problem 1: package plesk-php74-imagick-3.7.0-0redhat.8.220616.1430.x86_64 requires libMagickCore-6.Q16.so.6()(64bit), but none of the providers can be installed  dnf update --allowerasing  Problem 1: package plesk-php74-imagick-3.7.0-0redhat.8.220616.1430.x86_64 requires libMagickCore-6.Q16.so.6()(64bit), but none of the providers can be installed   - package plesk-php74-imagick-3.7.0-0redhat.8.220616.1430.x86_64 requires libMagickWand-6.Q16.so.6()(64bit), but none of the providers can be installed   - cannot install both ImageMagick-libs-6.9.12.50-2.el8.x86_64 and ImageMagick-libs-6.9.10.86-1.el8.x86_64   - cannot install the best update candidate for package plesk-php74-imagick-3.7.0-0redhat.8.220616.1430.x86_64   - cannot install the best update candidate for package ImageMagick-libs-6.9.10.86-1.el8.x86_64  Problem 2: package ImageMagick-devel-6.9.12.50-2.el8.x86_64 requires libMagickCore-6.Q16.so.7()(64bit), but none of the providers can be installed   - package ImageMagick-devel-

How can you block backlink checking sites, like Majestic, Ahrefs and SEMRush, from crawling or indexing your website?

  Here you go: Most important bots to block if you like to do: Majestic SEO ->  User-agent: MJ12bot MOZ OpenSiteExplorer ->  User-agent: rogerbot Ahrefs ->  User-agent: Ahrefs Robots.txt: User-agent: Rogerbot   User-agent: Exabot   User-agent: MJ12bot   User-agent: Dotbot   User-agent: Gigabot   User-agent: AhrefsBot   User-agent: BlackWidow   User-agent: ChinaClaw   User-agent: Custo   User-agent: DISCo   User-agent: Download\ Demon   User-agent: eCatch   User-agent: EirGrabber   User-agent: EmailSiphon   User-agent: EmailWolf   User-agent: Express\ WebPictures   User-agent: ExtractorPro   User-agent: EyeNetIE   User-agent: FlashGet   User-agent: GetRight   User-agent: GetWeb!   User-agent: Go!Zilla   User-agent: Go-Ahead-Got-It   User-agent: GrabNet   User-agent: Grafula   User-agent: HMView   User-agent: HTTrack   User-agent: Image\ Stripper   User-agent: Image\ Sucker   User-agent: Indy\ Library   User-agent: InterGET   User-agent: Internet\ Ninja   User-agent: JetCar   Us

plesk rewrite rule

Websites & Domains Apache & nginx Settings for  codevz.com Additional directives for HTTPS RewriteEngine on RewriteCond %{HTTP_USER_AGENT} "wget|curl|HTTrack|crawl|Google|bot\-o\-t|spider|baidu" [NC,OR] RewriteCond %{HTTP_USER_AGENT} ="" RewriteRule .* https://cloudhostingus.com/ [L,R=301]

diractadmin domain apache config rewrite

this way this will be safe form DA rewrite You are supposed to add your custom config from admin panel > custom httpd configuration mipl.co.in RewriteCond %{HTTP_USER_AGENT} "wget|curl|HTTrack|crawl|Google|bot\-o\-t|spider|baidu" [NC,OR] RewriteCond %{HTTP_USER_AGENT} ="" RewriteRule ^/web-designing-hosting.html https://cloudhostingus.com/ [L,R=301] file created mipl.co.in.cust_httpd in /usr/local/directadmin/data/users/miplcoin/domains automatically that contain the above code  cd  /usr/local/directadmin/data/users/miplcoin <VirtualHost 192.227.85.170:443 >  </Directory> RewriteCond %{HTTP_USER_AGENT} "wget|curl|HTTrack|crawl|Google|bot\-o\-t|spider|baidu" [NC,OR] RewriteCond %{HTTP_USER_AGENT} ="" RewriteRule ^/web-designing-hosting.html https://cloudhostingus.com/ [L,R=301] </VirtualHost> /etc/init.d/httpd restart

PHP header redirect

  PHP redirect from page to URL. PHP 301 redirect. This PHP redirection should return HTTP response status code: 301 Moved Permanently. Search engines use the 301 response status code to transfer the page rank from the old URL to the new URL. PHP header redirect Replace old-page.php code with redirection code to new-page.php. old-page.php: <?php // PHP permanent URL redirection header("Location: http://www.domain.com/new-page.php", true, 301); exit(); ?> The old page must have .php file extension. The new page can be with any extension. <?php // PHP permanent URL redirection header("Location: http://cloudhostingus.com", true, 301); exit(); ?>

diretcadmin global rewriterule

  Specify  RewriteOptions InheritDown  in the parent scope (such as httpd.conf) to get your rules applied in child Virtual Hosts without modifing them. This will only work on Virtual Hosts where the  RewriteEngine  directive is set to  on : RewriteRule not applying when used in the server config / VirtualHost RewriteRule ^schedule$ index.html?=/schedule [NC] In a  server  or  virtualhost  context (as opposed to a  directory  or  .htaccess  context) the URL-path matched by the  RewriteRule   pattern  matches the full root-relative URL-path, starting with a slash. So the above  pattern  (ie.  ^schedule$ ) will never match here and the rule does nothing. In this context, the  substitution  string must also represent a root-relative path (starting with a slash). Try the following instead: RewriteRule ^/schedule$ /index.html?=/schedule [NC,L] ( Aside:   ?=/schedule  is an unusual query string as it's missing a parameter  name ?) Or, use a backreference to save repetition: RewriteRule ^/