• How to configure OpenDKIM on Linux with Postfix and setup bind zonefile


    This guide assumes you have a working Postfix server and want it to sign with DKIM. There are a few things we have to understand to make all of this work though, which require you to be familiar with DNS as well. 1.) Install OpenDKIM apt install opendkim systemctl enable opendkim 2.) Edit /etc/opendkim.conf Syslog yes SyslogSuccess yes Mode&nbs........
  • Debian Ubuntu 10/11/12 Linux how to get tftpd-hpa server setup tutorial


    apt install tftpd-hpa #change TFTP_ADDRESS to by setting address to 192.168.1.1:69 or the IP you need, otherwise it will listen on all IPs and interfaces which could be a security risk. # edit /etc/default/tftpd-hpa TFTP_USERNAME="tftp" TFTP_DIRECTORY="/srv/tftp" TFTP_ADDRESS="192.168.1.1:69" TFTP_OPTIONS="--secure"........
  • efibootmgr: option requires an argument -- 'd' efibootmgr version 15 grub-install.real: error: efibootmgr failed to register the boot entry: Operation not permitted.


    This sometimes happens when trying to install the EFIversion of grub to a device when you are booted into Legacy/MBR mode. It doesn't seem to occur on all machines, but some and seems somewhat BIOS dependent. grub-install --target=x86_64-efi /dev/sda Installing for x86_64-efi platform. grub-install.real: warning: Couldn't find physical volume `(null)'. Some modules may be missing from core image.. grub-install.real: warning: Couldn't find physica........
  • isc-dhcp-server dhcpd how to get longer lease


    You can do a static lease that is tied to the MAC address but what a lot of users prefer is that they come into the office or lab the next day and that their device gets assigned the same IP address (if possible). As we can see in the dhcpd logs that there is threshold that is defaulted as we'll show later. Whatever the threshold is set at, if the lease is younger than the threshold, it will keep the same lease. In other words, if the device goes to sleep or is powered off........
  • nvidia cannot resume from sleep Comm: nvidia-sleep.sh Tainted: Linux Ubuntu Mint Debian


    This seems to happen in many different drivers but it happened more often in newer versions such as 530 vs 525. Then nvidia-modeset goes to 100% There are many reports of this appearing since driver 4.70 and I can confirm I've seen this in various machines. https://forums.de........
  • zfs and LUKS how to recover in Linux


    Sometimes users take their removal drives and unplug and replug them to test what happens during the failure of a disk. However, this breaks things quite badly due to the /dev/mapper in LUKS not coming back online due to it not being closed. In other words, generally with non-encrypted drives the process is smooth but when encrypted you may want to follow a strategy like this: We can see below that both disks are unavailable as they were physically remov........
  • [error] (28)No space left on device: Cannot create SSLMutex Apache Solution Linux CentOS Ubuntu Debian Mint


    Have you got this error from Apache? [notice] suEXEC mechanism enabled (wrapper: /usr/sbin/suexec) [error] (28)No space left on device: Cannot create SSLMutex At first glance it appears that you may be out of disk space but the issue is ipc or interprocess communication. This will clear out the ipcs processes so things can work, this often happens during high traffic and may be a sign of DDOS. The command below will fix it, it will list al........
  • du - VAS Billing Subscriptions Hack/Scam MLPremiumSub Invascom Astromart Issues Complaint


    If you have du, you may want to check your bill, as you can read about a longstanding issue with fraudulent charges showing up and many users claiming they did not subscribe or solicit those offers. These don't normally show up on new accounts, but they seem to target established users and maybe even users they suspect are not watching their phone or bills, while they are on vacation. These charges can frighteningly happen with 0 interaction from the user despite what........
  • When is it time to leave your VPS/VDS Cloud Hosting Provider?


    When Is It Time to Leave Your VPS, VDS, and Dedicated Server Provider? Choosing the right hosting solution—be it Virtu........
  • 2024 Buyer's Guide: How to Choose and Buy the Best VPS/VDS for Your Needs - Tips and Strategies


    In today’s digital landscape, finding a reliable and secure Virtual Private Server (VPS) or Virtual Dedicated Server (VDS) goes beyond just comparing specs and prices. With increasing concerns over data privacy, security breaches, and government surveillance, the wisdom of choosing your VPS/VDS provider based on juri........
  • Postfix / sendmail config for DKIM, SPF and DMARC Tutorial Guide E-mail Delivery for Hotmail.com Gmail.com and More HowTo


    This will be the goto to help solve e-mail delivery issues and talk about many practical issues that happen between developers, admins and scripts that send e-mail and do things that may not be acceptable or cause deliverability problems. Sendmail Stuff Edit /etc/mail/sendmail.mc The problem is that if you send directly out from the server using the mail function, the Return-path of the e-mails will be username@thehostnameoftheserver.com. Let........
  • Install Grafana on Linux Debian Ubuntu Tutorial Guide


    First we need a few extra packages: apt update apt install -y adduser libfontconfig1 musl sudo wget https://dl.grafana.com/enterprise/release/grafana-enterprise_10.3.1_amd64.deb Install / Enable Grafana dpkg -i grafana-enterprise_10.3.1_amd64.deb dpkg -i grafana-enterprise_10.3.1_amd64.deb (Reading database ... 44309 files and directories currently installed.) Preparin........
  • Mint Ubuntu Linux Gnome Showing Home Directory on Desktop instead of Desktop Directory


    During a migration or other custom setup, it's possible you don't have a $HOME/Desktop and as a result the config file that controls this is set to just use your $HOME directory. This is controlled in the file: $HOME/.config/user-dirs.dirs As we can see below, Desktop, Downloads, Music and Pictures are set to $HOME. We can edit any of these as we like. # This file is written by xdg-user-dirs-update # If you want........
  • How To Upgrade Debian 8,9,10 to Debian 12 Bookworm


    Step 1.) Upgrade to Debian 11 first The process to go to Debian 12 is not as smooth as 11, when trying to upgrade from Debian 10. In fact, it doesn't work directly, so you'll first need to follow this guide to update to Debian 11, reboot and come back here if successful. Step 2.) Update sources.list Update your /etc/apt/sources.list like this: deb http://........
  • apache2 httpd apache server will not start [pid 22449:tid 139972160445760] AH00052: child pid 23248 exit signal Aborted (6) solution Mint Debian Ubuntu Redhat


    If you get this error, it is often because you have configured Apache with modules that weren't actually installed. Eg. you try to load the PHPmodule but didn't actually install the apache2 php module, so the server can't start. In general, this error can often be caused by issues with problematic modules and/or Apache being configured for modules that have not actually be installed (eg. libapache2-mod-php) is missing. The above results in this less than obv........
  • How To Setup Python3 in Ubuntu Docker Image for AI Deep Learning


    The issue is that Docker images are stripped down, so many tools and even python3 is missing, so you'll have to build or update the actual image yourself. I assume you have started an image with something like this and that you have the Nvidia Toolkit installed (assuming you are using GPUs). If you're not using nvidia just remove --runtime=nvidia --gpus all. docker run -it --runtime=nvidia --gpus all ubuntu bash These works for most images li........
  • ecryptfs how to manually encrypt your existing home directory or other directory


    Just in case, it is reocmmended to backup the original contents of the directory (especially your home dir) before proceeding. Setup ecryptfs Run this command: ecryptfs-setup-private It will ask you for your login password, this is so that when you login, everything is automatically decrypted by using a passphrase that is wrapped with your login. You can hit enter and leave things blank for an autogenerated passphrase (for mounting) or you can en........
  • Firefox how to restore and backup saved passwords and history which files/location


    The passwords are stored in the following locations on Unix/Linux: The directory is usually inside your home like this: ~/.mozilla/firefox logins.json contains the locations, username and password key*.db (usually then name could be key3.db or key4.db) Without the key file you will not see any passwords in Firefox as it is required to in order to decrypt the contents of logins.json........
  • ecryptfs how to change default mount location from Private Ubuntu Debian Centos How


    In a lot of distros like Debian, ecryptfs will mount itself in /home/yourusername/Private This is controlled by Private.mnt which may contain the mount path like this: /home/yourusername/Private Change the default mount location of ecryptfs by modifying this file: home/.ecryptfs/yourusername/.ecryptfs/Private.mnt After you unmount and relogin, you should find ecryptfs is now mo........
  • How to upgrade to the latest Python version on Linux Ubuntu Debian Mint 3.11


    A lot of developers want to go to 3.11 because of the speed improvements, but most distros never have the latest Python version. Using the deadsnakes third party repo is the easiest way aside from compiling it yourself (which is safer and recommended): Step 1 - Add the repo apt-add-repository ppa:deadsnakes/ppa If you get an error about requests then install it:........
  • How to install and configure haproxy on Linux Ubuntu Debian


    haproxy is one of the best known and widely used Open Source load balancers out there and a strong competitor to nginx. haproxy is used by many large sites per Wikipedia: HAProxy is used by a number of high-profile websites including GoDaddy, GitHub,........
  • talib/_ta_lib.c:747:10: fatal error: ta-lib/ta_defs.h: No such file or directory


    If you are installing ta-lib for Python and get this error then you can normally solve it by manually getting the ta-lib source files and compiling. tar -zxvf ta-lib-0.4.0-src.tar.gz cd ta-lib;./configure;make;make install Collecting ta-lib Downloading https://files.pythonhosted.org/packages/39/6f/6acaee2eac6afb2cc6a2adcb294080577f9983fbd2726395b9047c4e13ec/TA-Lib-0.4.26.tar.gz (272kB) &nbs........
  • Virtualbox Best Networking Mode In Lab/Work Environment without using NAT Network or Bridged


    Virtualbox is a very powerful tool, but for some use cases it is less than optimal. Say you are in a work, lab or other environment where you are not alone on the physical network and there could be overlap of IPs, but you need all of your VMs to be contactable from your host, VMs need to communicate with each other, and VMs need internet. NAT Network will give you VM to VM communication and internet, however, it is buggy and unstable. It also doesn't allow host to VM co........
  • debootstrap how to install Ubuntu, Mint, Debian install


    In this example we install debian 10 with --variant=minbase which gives us a minimal/tiny install. Don't use variant if you want the full size install. mkdir /tmp/deb10files debootstrap --variant=minbase buster /tmp/deb10files/ Did you get an error? debootstrap --variant=minbase buster /home/theuser/VMs/deb10files/ You'll get this error if you make a directory in your home........
  • VboxManage VirtualBox NAT Network Issues Managment Troubleshooting


    If you find your NAT Network is not working properly, the first thing you may want to do is list the networks, check their status and make sure the Network is actually started and configured as you expect (eg. is DHCP on and enabled?). This is a long known, unresolved bug that seems to affect Version 6 randomly and disportionately on especially Mint 20/Ubuntu 18. https://www.virtualbox.org/ticket/1474........
  • Dell PowerEdge Server iDRAC Remote KVM/IP Default Username, Password Reset and Login Information Solution


    Are you new to the company, datacenter or a third party who is responsible for deploying a fleet of servers from scratch. The first step is to normally login to the KVM so you can perhaps manually reinstall, PXE boot the Cloud Image or reimage/reinstall an OS but you need access to the KVM/IP or what Dell calls iDRAC. It's common that you may have forgotten this information or that another employee or colleague has changed the info and did not tell you, that they have left the........
  • docker / kubernetes breaks Proxmox QEMU KVM Bridge VMs


    Docker adds iptables rules that break a lot of things including MASQUERADE or anything that needs the FORWARD table. If NAT is not working after Docker installation, it is probably because it set the iptables FORWARD policy to DROP. This may also make you think that your br0 or bridge is not working, but it's likely just due to what we'll mention later on below, that, Docker probably set your FORWARD chain to default DROP all packets, so nothing on your bridge ever makes it out........
  • Cisco UC CME How To Enable Licensed Features


    Router#show license Index 1 Feature: ipbasek9 Period left: Life time License Type: Permanent License State: Active, In Use License Count: Non-Counted Lic........
  • from pip._internal.cli.main import main File "/usr/local/lib/python3.5/dist-packages/pip/_internal/cli/main.py", line 60 sys.stderr.write(f"ERROR: {exc}") from pip._internal.cli.main import main File "/usr/local/lib/python3.5/dist-packag


    Solution for python pip3 not working anymore from pip._internal.cli.main import main File "/usr/local/lib/python3.5/dist-packages/pip/_internal/cli/main.py", line 60 sys.stderr.write(f"ERROR: {exc}") wget https://bootstrap.pypa.io/pip/3.5/get-pip.py python3 get-pip.py DEPRECATION: Python 3.5 reached the end of its life on September 13th, 20........
  • ModuleNotFoundError: No module named 'pip._internal' solution python


    pip3 install requests Traceback (most recent call last): File "/home/user/.local/bin/pip3", line 7, in from pip._internal.cli.main import main ModuleNotFoundError: No module named 'pip._internal' As a quick and temp fix call the OS installed python and not the user .local/bin installed pip3 /usr/bin/pip3 install requests Collecting requests Cache e........
  • Cisco Switch / Router How To Restore Factory Default Settings


    1.) Make sure your conf register is 0x2102 Do show version and at the very end of the output you will see the Configuration register. show version Configuration register is 0x2102 If the config register is not 0x2102 then enter this command: r1#configure terminal r1(config)#config-register 0x2102 r1(config)#end 2.) Let's Erase the NVRAM/flash........
  • ecryptfs How To Backup / Migrate Linux Mint Ubuntu Debian system ecryptfs properly and restore access


    In this scenario, let's say you want to clone your OS at the filesystem level and the source system (the system you want to clone from) is in use. Doing a blind rsync / is a big problem because it uses twice as much space for no reason. The reason for this is that with ecryptfs you have a /home/.ecryptfs directory which has the actual encrypted versions of your files and folders. However your home directory (eg. /home/someuser) is mounted. Doing the blind rsync will ca........
  • i915 nouveau Nvidia GPU not starting lightdm Xorg failing solution for Could not determine valid watermarks for inherited state


    It may appear to be an Xorg or lightdm/gdm/mdm error but in reality for many users with this issue, it's a driver conflict and issue. I had a system that had two GPUs, an Intel and Nvidia GPU. The only thing that got it working was to remove the nouveau driver and blacklist it so it never came back, then the Intel GPU works fine without these issues. Solution sudo rmmod nouveau add nouveau/other driver to blacklist edit th........
  • Debian Mint Ubuntu Howto Disable Network Manager


    NetworkManager is normally good for GUI users who may not be good with manually confguring devices, but if you are using things like bridging and bonding, it will often break things. How To Disable NetworkManager systemctl disable NetworkManager Now that it's disabled you will need to stop NetworkManager. NetworkManager will still be running until you reboot next or manually stop it. How To Stop NetworkManager systemctl stop........
  • How To Tell Which Repository a Package Comes From Debian Mint Ubuntu


    Just use apt-cache policy to find the repo of a package: apt-cache policy lxd lxd: Installed: 3.0.3-0ubuntu1~18.04.2 Candidate: 3.0.3-0ubuntu1~18.04.2 Version table: *** 3.0.3-0ubuntu1~18.04.2 500 500 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 Packages &nb........
  • ssh Too many authentication failures not prompting for password


    If you get this error when trying to SSHto a device or machine and you never even got a password prompt: Too many authentication failures This means that either the remote side is configured for key auth only, OR your client side may be attempting to auth using mulitple keys, and that exceeds the amount of attempted authorizations on the remote ssh server. If the issue is trying to auth too many times which ssh defaults to sending the keys to, you ca........
  • LightDM Mint Ubuntu Debian won't start errors Nvidia Graphics


    This error implies that there may be an issue with Xorg or maybe your NVIDIA GPU cannot start or initialize: 35 laptop kernel: [ 2031.857704] nvidia: loading out-of-tree module taints kernel. 35 laptop kernel: [ 2031.857724] nvidia: module license 'NVIDIA' taints kernel. 35 laptop kernel: [ 2031.857725] Disabling lock debugging due to kernel taint 35 laptop kernel: [ 2031.873280] nvidia: module verification failed: signature a........
  • LXC Containers LXD How to Install and Configure Tutorial Ubuntu Debian Mint


    If you are using mint, delete the preference that stops snap from installing (as it is required for lxc) sudo rm /etc/apt/preferences.d/nosnap.pref 1. Install lxd: sudo apt install lxd Issues install lxd or errors? Click here Debian at this time does not have lxd so you'll need to use snap: sudo apt in........
  • GlusterFS HowTo Tutorial For Distributed Storage in Docker, Kubernetes, LXC, KVM, Proxmox


    This can be used on almost anything, since Gluster is a userspace tool, based on FUSE. This means that all Gluster appears as to any application is just a directory. Applications don't need specific support for Gluster, so long as you can tell the application to use a certain directory for storage. One application can be for redundant and scaled storage, including for within Docker and Kubernetes, LXC, Proxmox, OpenStack, etc or just your image/web/video files or even da........
  • How To Enable Linux Swapfile Instead of Partition Ubuntu Mint Debian Centos


    This may be necessary if you have a VM or if for some reason you just want to be more efficient with your space and have the flexibility of changing your swap space at will. What we mean is the ability to use a "swap file" or similar to the Windows "pagefile" that normally resides on the root or c: partition of Windows. Here's all you have to do and then you to can have a single partiton with everything, including the swap file on the root partition if you........
  • 404 Not Found [IP: 151.101.194.132 80] apt update Debian 11 Bullseye Solution The repository 'http://security.debian.org bullseye/updates Release' does not have a Release file.


    This happens during an apt update and is related to an issue with sources.list, which is particularly troubling, if you are doing a "live-build". P: Configuring file /etc/apt/sources.list Hit:1 http://deb.debian.org/debian bullseye InRelease Get:2 http://deb.debian.org/debian bullseye-updates InRelease [39.4 kB........
  • Docker Tutorial HowTo Install Docker, Use and Create Docker Container Images Clustering Swarm Mode Monitoring Service Hosting Provider


    The Best Docker Tutorial for Beginners We quickly explain the basic Docker concepts and show you how to do the most common tasks from starting your first container, to making custom images, a Docker Swarm Cluster Tutorial, docker compose and Docker buildfiles.........
  • How To Startup and Open Remote/Local Folder/Directory in Ubuntu Linux Mint automatically upon login


    Just click on the Start Menu and go to "Startup Applications" Then click on the "Add"Button Now enter the command we need to open the folder/directory automatically using the filemanager For remote SSH host (you need pub key auth for it to open without a pa........
  • How To Create OpenVPN Server for Secure Remote Corporate Access in Linux Debian/Mint/Ubuntu with client public key authentication


    Why choose OpenVPN instead of a firewall appliance? OpenVPN can be a reliable and easy replacement for traditional hardware or just be an additional tool that your company uses so that the firewall can focus on its job rather than acting as a VPNappliance at the same time. When comparing OpenVPN with traditional firewal........
  • HongKong VPS Server, Cloud, Dedicated Server, Co-Location, Datacenter The Best Guide on Hong Kong, China Internet IT/Computing


    In our 2024 VPS Server/Cloud Buyer's Guide, we place the location of your VPS/hosting/server as one of the priorities that is often overlooked. 2024 Update - Datacent........
  • Wazuh / OSSEC Install and Configuration Howto Tutorial Guide for Monitoring Agents SIEM


    How To Install Wazuh Server / Quickest Installation Wazuh (forked from the well known OSSEC project) is a full SIEM (Security Information Event Management) that works extremely well with the platforms it natively supports as an "Agent", which allows you to do scans of everything such as all processes running, CVE vulnerability check, incident reporting etc... Prerequisites: A lot of issues with Wazuh seem to be caused by i........
  • Linux Debian How To Enable Sudo/Sudoers for User "User not in sudoers file" Solution


    If you get an error that you aren't in the sudoers file, this typically means that your user is not designated as an admin with sudo privileges. In plain English, when it comes to some OS's like Debian including 10,11 etc.., by default the user is created without special privileges which is contrary to how Ubuntu/Mint handle the secondary user. Let's check the sudoers file to see the problem.........
  • How to allow SSH root user access in Linux/Debian/Mint/RHEL/Ubuntu/CentOS


    A lot of newer installs will automatically prohibit the root user from logging in directly, for security reasons or they will only allow key based access. If you know what you are doing/don't care about security or have an incredibly secure password for testing, then you can enable it. Edit this file: /etc/ssh/sshd_config Find the following line: PermitRootLogin Set it like this: PermitRootLogin yes Now rest........
  • Ansible Tutorial - Playbook How To Install From Scratch and Deploy LAMP + Wordpress on Remote Server


    1. Let's work from an environment where we can install Ansible on. If you are using an older version of Linux based on Mint 18 or Ubuntu 16, you may want to get the PPA and get the latest version of Ansible that way: sudo apt install gpg sudo add-apt-repository ppa:ansible/ansible sudo apt update........
  • Proxmox Update Error https://enterprise.proxmox.com/debian/pve bullseye InRelease 401 Unauthorized [IP: 144.217.225.162 443]


    Are you getting this error in Proxmox while trying to apt update or install Ceph? apt update Hit:1 http://security.debian.org bullseye-security InRelease Err:2 https://enterprise.proxmox.com/debian/pve bullseye InRelease 401 Unauthorized [IP: 144.217.225.162 443] Hit:3 http://ftp.hk.debian.org/debian bullseye InRelease ........
  • pulseaudio issue on QEMU/KVM guest VM when microphone is replugged/unplugged pulseaudio: pa_threaded_mainloop_lock failed pulseaudio: Reason: Invalid argument


    Here is the scenario, you are using QEMU/KVM and are using something like the AC97 sound driver to pass the host audio to the guest via pulseaudio. This is useful because you can transparently pass your mic input from the host which means you can mute your microphone from the host, which prevents the guest from receiving any mic input even if unmuted. Mute / Unmute Fix This issue also seems to happen even if you press the mute button on the microphone and then unmute,........
  • Linux Mint 20 cannot install snapd missing solution


    The Linux Mint team has disabled it by setting an apt preference, you can edit or just remove the file: sudo apt install snapd Reading package lists... Done Building dependency tree Reading state information... Done Package snapd is not available, but is referred to by another package. This may mean that the package is missing, has been obsoleted, or is only available from another source........
  • How to install Kubernetes with microk8s and deploy apps on Debian/Mint/Ubuntu Linux


    Kubernetes Easy Beginners Architecture Guide Kubernetes is known as container orchestration and we should start at explaining the container part of it. A Container is what runs the actual application and based on an Image, and are more comparable to something like an LXC Container, Virtuozzo/OpenVZ using the Linux Kernel Namespaces feature. Containers run these images as independent, isolated operating environments under the OS's exist........
  • Cisco Howto Configure Console Port/Terminal/Comm Server with Async Cable Setup


    This assumes that you've already installed the relevant HWIC cards eg. Cisco Asynchronous Serial NIM These are essentially cards that you install into your router, once installed you connect an Async cable to one of the ports on the card which normally gives you 8 console cables and are normally labelled 1 through 8. You connect all of the cables to the devices you need (even non-Cisco devices) whether switches, routers or firewalls, they will usually work. The real m........
  • SSH cannot connect to old servers/devices/switches/routers/Cisco/Juniper Unable to negotiate with 192.168.20.2 port 22: no matching key exchange method found. Their offer: diffie-hellman-group-exchange-sha1,diffie-hellman-group14-sha1,diffie-hell


    A lot of older devices either support telnet or very old SSH keyx algorithms which are insecure and disabled by all newer/modern SSH clients for security reasons. However, sometimes you may be on a LAN via VPNor some other secured network or for whatever reason, absolutely, need to connect to this device and sometimes old/embedded devices may not be possible to update to a newer SSH server. If you run into this you may be using a modern/newer SSH client and get thi........
  • bash how to hide username/customize prompt Linux Debian Redhat Ubuntu Solution


    Just edit your ~/.bashrc and add this at the very end: export PS1="realtechtalk.com" Then your prompt will look like this: bladeblox:uptime 08:47:14 up 48 min, 1 user, load average: 1.00, 1.07, 0.96 If you wanted a dollar sign at the end then you would change it like this: export PS1=&........
  • Juniper JunOS Command Overview and Howtos Switch, Router, Firewall Tutorial Guide


    Enable "cli" mode equivalent in JunOS cli Configure Mode configure So rather than going to the console on a Cisco switch and typing "enable" and then "conf t", the equivalent in JunOS is "cli" and "configure". How Do You Apply Changes You've Made? You can make all kinds of changes to the switch, but remember they are not........
  • Aruba/HP/Dell IAP Wireless Controller Common Default Passwords


    Aruba has a very traditional "admin" for user and password by default for many of its appliances. If you've reset or just got some new units this will be the default password that you should change immediately for security reasons.........
  • How To Boot, Install and Run Windows 2000 on QEMU-KVM


    Interestingly enough Windows 2000 works fine on QEMU 64-bit but you have to specify Pentium as your CPU otherwise it doesn't complete the install (it will not pass the detecting/setting up devices phase). -vga cirrus is wise because it is supported by Windows 2000 and allows higher resolutions and 24-bit color. -cpu Pentium emulates an old computer and is necessary for install to complete -device rtl8139 is important as this oldschool Realtek 8139 NIC is supported by W........
  • bash cannot execute permission denied


    $ ./test.sh bash: ./test.sh: Permission denied This happens normally because you are on a partition that was mounted as "user" and without the exec option. Also be sure to add exec at the end so no other options set noexec. Change your fstab or add exec to your mount options: /dev/md127 /mnt/md127 ext4 auto,nofail,noatime,rw,user,exec 0 0 ........
  • Linux Mint/Debian/Ubuntu/Centos Installer black grub screen and blank screen after trying to boot installer or main OS


    This happens to a lot of Nvidia users especially users of newer cards like the RTX series. If for example you are trying to boot and install Linux and you get a black and white grub2 screen instead of a nice graphical welcome installer, you probably suffer from this bug. It is normally followed by the user booting and finding they just have a blank/black screen. Here is the quick flow of steps to fix it: If you get a black grub scree........
  • How To Password Reset, Recover, Bypass, Remove and Unlock on Windows 10,8,7,Vista,XP,NT,2000,2003,2008,2012,2016,2019 Administrative Login Programs


    If you've come here, don't be embarraassed, working in IT, this is the MOST common computer problem that almost everyone will encounter. The reason why I'm doing this post is because I've seen an increase from colleagues and admins having this problem and many times it's not even your fault. A common scenario is that someone acquires a new or used computer which they weren't given the password for. Fortunately Ihave a detailed list of all the options whether free or pa........
  • How To Get Started on Ubuntu with gpt-2 OpenAI Text Prediction


    apt install software-properties-common add-apt-repository ppa:deadsnakes/ppa apt update apt install python3-pip apt install python3.7 curl gnupg python3.7-dev git ln -s /usr/bin/python3.7 /usr/bin/python3 pip3 install numpy keras_preprocessing curl https://bazel.build/bazel-release.pub.gpg | sudo apt-key add - echo "deb [arch=amd64] http://storage.googleapis.com/bazel-apt stable jdk1.8" | sudo tee /etc/apt/sources.list.d/bazel........
  • QEMU-KVM KVM Command Line Practical Guide


    Iam going to build this based on a series of small howto QEMU / KVMposts I've made as I feel much of the information is actually hard to find and piece together from the rest of the web. What I'm going to focus on is how to use virtio as the NIC because if you don't you get very slow NIC speeds but with the virtio NIC model you basically get host speeds. /usr/libexec/qemu-kvm -enable-kvm -smp 8 -m 16000 -net user -net nic,model=virtio -drive file=ubuntu-gpt2l........
  • virt-resize: error: libguestfs error: could not create appliance through libvirt.


    This is caused because the user is running as qemu for virt-resize and if qemu does not have privileges to read from the source and write to the destination, it will fail with the below. So either change the uid of qemu or change the ownership of the source and target. Solution: export LIBGUESTFS_BACKEND=direct virt-resize --expand /dev/sda2 /root/kvmtemplates/windows2019-eval-template.img /root/kvmguests/kvmkvmuser4515........
  • Asterisk Does Not Retry When Authentication Fails


    When authentication times out that is one thing, but when it just fails like below Asterisk by default will not re-register until you the admin reload the sip or asterisk server: voipserver*CLI> sip show registry Host dnsmgr Username Refresh State&........
  • How To Install NextCloud on Centos 7 and Centos 8


    yum -y install wget unzip wget https://download.nextcloud.com/server/releases/nextcloud-18.0.2.zip unzip nextcloud-18.0.2.zip yum -y install php php-mysqlnd php-json php-zip php-dom php-xml php-libxml php-mbstring php-gd mysql mysql-server Last metadata expiration check: 0:58:02 ago on Fri 13 Mar 2020 02:12:49 PM EDT. Dependencies resolved. ===================================================================........
  • How To Install python 3.4 3.5 and up on Linux with wine - Working Solution


    This is sure simple if you follow the guide but it took a lot of hacking around to make this work on Debian/Ubuntu! Now before you ask why bother running wine and python, the reason is because Python executables are NOT cross-platform. If you run pyinstaller in Linux, that binary will only run on Linux and the same if you do it in Windows. So it is preferable if you have a single environment that you can create Linux and Windows binaries from rather than running 2 separate........
  • OpenVZ vs LXC DIR mode poor security in LXC


    It is unfortunate that LXC's dir mode is completely insecure and allows way too much information from the host to be seen. I wonder if there will eventually be a way to break into the host filesystem or other container's storage? OpenVZ better security: [root@ev ~]# cat /proc/mdstat cat: /proc/mdstat: No such file or directory /dev/simfs 843G 740G 61G........
  • MySQL 5.7 on Debian and Ubuntu - How To Reset Root Password


    MySQL on Debian versions is configured differently than the native local MySQL plugin so you will be disappointed when your password on the mysql client fails by default. Here is how you reset the MySQL root password the proper and "working way" #first we gracefully stop mysql sudo systemctl stop mysql; #then we forcefully kill any mysqld process just in case sudo killall -9 mysqld mysqld_safe;........
  • Linux How To Add User To Additional Group


    sudo usermod -a -G groupname username It's really simple like above, the -a is for append so that you are not changing their main group, but adding them to another additonal group. Just change "groupname" to your group and "username" to the user you want to be added to "groupname". A common task these days is getting your user access to kvm for virtualization so the KVM/QEMUprocess........
  • CentOS 8 how to convert to a bootable mdadm RAID software array


    The cool thing here is that we only need 1 drive to make a RAID 10 or RAID 1 array, we just tell the Linux mdadm utility that the other drive is "missing" and we can then add our original drive to the array after booting into our new RAID array. Step#1 Install tools we need yum -y install mdadm rsync Step #2 Create your partitions on the drive that will be our RAID array Here I assume it is /dev........
  • Linux Mint / Ubuntu / Debian Mate Disable Guest Session and Hide Usernames on Lightdm Login screen GUI


    sudo vi /etc/lightdm/lightdm.conf.d/70-linuxmint.conf Change this: [SeatDefaults] user-session=mate allow-guest=false To this: [SeatDefaults] user-session=mate allow-guest=false greeter-hide-users=true greeter-show-manual-login=true To see and apply your changes just restart light........
  • python ModuleNotFoundError: No module named 'bs4' even though you have the module


    In this case I am executing using "python3" but what you find in cases like this can be surprising. The most common issues are that someone has a module for python 2 "pip" and doesn't realize they need "pip3" to install it for python3, but this is not one of those cases. ModuleNotFoundError: No module named 'bs4' OKmaybe we didn't install it for python3? [........
  • ssh how to connect using a SOCKS 5 proxy with nc and proxycommand


    This is not about using ssh as a proxy, but rather, using a proxy when you are SSHing to another host and using ProxyCommand (where we normally use nc as our proxy tool). In newer versions of nc the syntax has changed to the following: ssh -o ProxyCommand="nc -x 127.0.0.1:1234" %h %p user@host The format must be like above in newer nc versions. Just be sure to change the 1234 to the port of your SOC........
  • apache symlinks denied even with followsymlinks


    Symbolic link not allowed or link target not accessible: /path/httpdocs/news.html There are a few reasons that can cause this message and this is for people who have ruled out the basics, eg. your symlinks are enabled and the right permissions are applied (but read on to learn about ownership requirements above the directory in question). So there are a few key things here that cause Apache not to follow symlinks:........
  • chown how to change ownership on a symlink


    If you just do a normal chown user.user somedir it won't work. You will see the ownership is still the previous owner. How To Change Ownership Of Symlink: The simplest part is just adding the -h which means no dereference so it applies the ownership on the symlink and does not try (and fail) to change ownership of the dereferenced symlink destination. chown -h user.user somedir........
  • Wordpress Reset Blog User Password from MySQL Using Linux Bash and not PHPMyadmin


    The reason we use the command below is because we need the md5sum value hash of the password. This means that we cannot use the md5sum Change "yournewpass" to the pass you want to set echo -n "yournewpass" | md5sum Then you get the md5sum hash of whatever you entered eg. in this case "yournewpass" 5a9351ed00c7d484486c571e7a78c913 ........
  • MariaDB / MySQL Reset Root Forgotten Password on Centos 7


    mysql reset root password. Oops I can't remember my MySQL root password! [root@centos7test etc]# mysql -u root -p Enter password: ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES) First we need to stop mariadb: systemctl stop mariadb Now we need to restart it with skip-grant-tables whic........
  • Centos 7 How to install Mysql/Mariadb


    yum -y install mariadb-server systemctl start mariadb mysql_secure_installation Now we need to secure our install and set the MariaDB root password: The lines you need to act on are marked in bold shown with the answer you need. mysql_secure_installation NOTE: RUNNING ALL PARTS OF THIS SCRIPT IS RECOMMENDED FOR ALL MariaDB SER........
  • Linux Console Login Screen TTY Change Message


    This is all controlled by /etc/issue You can basically enter anything in there that you like, but there are preset variables that are mentioned at the end of the page that discuss this. Some examples of /etc/issue: Centos 7: S Kernel r on an m Ubuntu 16.04: Ubuntu 16.04.6 LTS n l You can also insert any of t........
  • MySQL Bash Query to pipe input directly without using heredoc trick


    Most of us know the heredoc method but what if you need a basic query done repeatedly and manually while working from bash? It is a pain to manually type mysql and login each time. With this command below you can semi-automate those queries: echo "use somedb; select * from auctions" | mysql -u root --password="yourpassword" Just modify the above to suit your needs and you can add more queries by adding a sem........
  • MySQL Cheatsheet Guide and Tutorial


    Create Database: create database yourdbname; Show All Databases: show databases; Change Database: use mysql; Drop / Delete a MySQL Database: drop database nameofyourdatabase;........
  • Linux tftp listens on all interfaces and IPs by DEFAULT Security Risk Hole Solution


    Just edit your tftp file for xinetd like this: *Change the IPto be the IPof the interface you want to listen on. To test if your tftp is available on a certain IP range use nc -u yourip 69 to see if you can still connect (/var/log/messages or /var/log/syslog) should show the connection if it is open. Oct 13 23:20:34 01 xinetd[26631]: Started working: 1 available servic........
  • qemu-kvm error "Could not initialize SDL(No available video device) - exiting"


    Now older versions of qemu-kvm didn't throw this error say if you just had "-video cirrus" when starting qemu-kvm. But newer versions do care. And this probably only applies to you if you are running from bash/terminal with remote kvm images. What you need to do is remove the "-video" part and just add -vnc :5 eg. this would fix the error: qemu-system-x86_64 -enable-kvm -boot order=cd,once=dc -m 1024 -drive........
  • Apache htaccess and mod_rewrite how to redirect and force all URLs and visitors to the SSL / HTTPS version


    It is really simple using .htaccess with mod_rewrite. Here is all you need: RewriteCond %{SERVER_PORT} 80 RewriteRule ^(.*)$ https://site.com/$1 [R=301,L] Another more graceful way is to use the %{SERVER_NAME}variable to make it dynamic. Just be careful that the server name will always match what you expect. (eg. if you are doing load balancing or clustering what if the server name may be somethi........
  • python 3 pip cannot install mysql module


    python3 testserver.com-car-scraping.py html.txt Traceback (most recent call last): File "testserver.com-car-scraping.py", line 5, in import mysql.connector ImportError: No module named 'mysql' For some reason it won't install properly even though I have the mysql client on this machine installed too. Solution: You need the mys........
  • Virtualbox vbox not starting


    If you've just installed VBox and it is not starting or working, the most common problem is usually that you don't have your kernel source installed, which means there is no kernel driver for vbox so it can't work. You may get an error that says "Kernel driver not installed" in your Virtualbox. So the first thing you should do is install your kernel source by running this: sudo apt-get install linux-headers-`uname -r`........
  • Bind / named not responding to queries solution


    By default bind will not respond to outside queries for security reasons. In most distributions you will find the default in /etc/named.conf looks like this at the top under options: listen-on port 53 { 127.0.0.1; }; listen-on-v6 port 53 { ::1; }; directory "/var/named";........
  • Linux Mint Mate Customize the Lock screen messages and hide username and real name


    This is a security hole in my opinion and should be plugged by editing the lock screen ui layout: vi /usr/share/mate-screensaver/lock-dialog-default.ui #find these objects and set the visible property to false object class="GtkLabel" id="note-tab-label" object class="GtkLabel" id="auth-username-label> object class="GtkLabel" id="auth-realname-label"........
  • ssh how to verify your host key / avoid MIM attacks


    SSH helps keep us secure in many ways, one of those is the host-key fingerprint which is unique. If you have been connecting to an SSH server that you've made no changes to and suddenly ssh warns that the key doesn't match then you have a problem. But how about connecting to an existing server for the first time on a new machine or client? A lot of new clients calculate it using an SHA256 hash but it is not as easy on your host machine to produce the sam........
  • Linux Mint 18 Disable User Name List from showing on Login Screen


    Click "Administration" ->"Login Window"........
  • Cisco Unified Communications Manager / CUCM IP 8.6,10,12 Install Error Solution


    Install Errors on Version 12: This error happened on QEMU emulator version 2.11.1 pve-qemu-kvm_2.11.1-5 on Proxmox/Debian but installing on QEMU.12 on Centos 6 did not produce the error. *Update it is not related to the OS or QEMU version. This happened in Centos 6 too after a second install. What really causes this even though you successfully install........
  • Ubuntu Debian Mint Linux SSHD OpenSSH Server Not Starting After Reboot Solution


    If you get error messages like this it is usually because /var/run/sshd does not exist. root@userbox:/# service sshd status ● ssh.service - OpenBSD Secure Shell server Loaded: loaded (/lib/systemd/system/ssh.service; enabled; vendor preset: enab Active: failed (Result: start-limit-hit) since Wed 2019-04-10 02:24:44 EDT; 1 Process: 511 ExecStartPre=/usr/sbin/sshd -t (code=exited, status=255)........
  • Cisco Unified Communications Manager 12 Install Errors on Proxmox/KVM


    The strange thing is that usually the first install or two will work on any new machine but then it suddenly won't. I had this experience on QEMU 2.13 on a different machine. There is something finicky or buggy about the CUCM installer even when choosing the same virtual hardware specs. qemu-kvm command: /usr/libexec/qemu-kvm -version QEMU PC emulator version 0.12.1 (qemu-kvm-0.12.1.2-2.506.el6_10.1), Copyright (c) 2003-2008 Fabrice Bellard ........
  • SSH Keep Alive To stop Disconnections


    Are you tired of coming back to your computer only to find your SSH connections have been broken? Even worse are the ones that hang where it appears to be connected but it is really not. The one option you have is an SSHclient side modification to send KeepAlive packets, sometimes this can also keep up your WiFi connection and stop it from disconnecting you as well. To make the keep alive changes for your just yourself (not system wide)........
  • the sign-in method you're trying to use isn't allowed. For more info, contact your network administrator - solution for active directory


    This is usually because the Group Policy forbids that user or group from logging in. run "gpmc" (not "gpedit.msc" as that is for local computer settings when you are not using Active Directory) or go to Administrative Tools and Group Policy Management. Edit the default domain policy like below........
  • Linux bash prompt why does it not show username@host and the current directory?


    Perhaps you've just seen this in the bash prompt: -bash-4.1# Instead of the expected user@hostname# It is probably because you are missing .bash_profile or .bashrc in your home directory Check for yourself: ls -al ~/|grep -E ".bash_profile|.bashrc" -rw-r--r--. 1 root root&nbs........
  • SSH persistent and automatic login script for proxy


    #!/bin/bash sshcommand="ssh -N -R 20000:localhost:22 user@8.8.8.8" result=`ps aux|grep $sshcommand"|grep -v grep` if [ -z "$result" ]; then echo "we are going to connect" $sshcommand else echo "we are already connected" fi This is a handy script you can use and then add it to cron. Save........
  • SSH proxy/command in the background or from cron script


    If you have an SSHproxy that you need to run automatically from cron you will need it in the background to work. ssh -N -D 22000 user@domain.com Basically the -N let's it continue running in the background.........
  • ssh reverse proxy to enable remote access behind a LAN and firewall


    So say you are behind a typical NAT/LAN setup whether at home, work or while travelling. What if you have a computer or server that you need to connect to from the outside? Yes you could use a VPN but a quick and dirty, temporary and secure way is to use SSH's Reverse Tunneling Proxy feature. Requirements On the remote ssh server host you need the GatewayPorts option enabled in sshd_config (be........
  • Cisco Router Setup Guide and Tutorial Howto With Commands and Examples


    In most of the Cisco router IOS I find the ports like ge0/0 ge0/1 and ge0/2 or whatever your ports are down. They will not even give you a link light. So one of the first tasks should be getting the port you are working with up. In my case the first goal is often connectivity with the LAN and WAN. LAN = your local area network (eg. in the office/home ) WAN= your ISP/public internet (eg. fiber/cable/dsl/ethernet).........
  • Linux Mint 18.2 Create Config File To Start Application Upon Login


    This is not about systemd/systemctl and not about "onboot" so there's no rc.local trick here but it's the GUI/Gnome etc when a user logs in that a command is launched. Put this in your home dir The .config/autostart directory is where Linux Mint/Ubuntu checks for autostart application config files mkdir -p ~/.config/autostart Create a new entry/file that starts an application........
  • sudoers file in /etc warning about comments/includes!


    If you see this in /etc/sudoers it is NOT a comment but an include. #includedir /etc/sudoers.d For example in Linux mint sudoers.d contains the following files: casper mintupdate README casper for example contains the following sudoers line: mint ALL=(ALL) NOPASSWD: ALL So if you are messing ar........
  • Centos 7 Reallocate logical volume space to another


    Do you hate how Centos 7 defaults to allocating most of your valuable space to /home even though it is a production server? Here is a quick guide on how to take back that space live, while online (of course make sure you have backups just in case something goes wrong!): First we will reduce our home dir by 100G: lvreduce -L -100G /dev/mapper/centos-home WARNING: Reducing active and open logical volume to ........
  • Using Microsoft's Group Policy Management Editor (GPME) To Change Default Permissions and Internet Explorer Security Settings


    The defaults in Windows 2016 server leave clients crippled so they can't even download basic files or software. But Group Policy Management Editor comes to our rescue! Use cmd or Powershell and run: gpme.msc Choose your domain/computer and then navigate like below and create a new menu entry for IE11 or whatever your version is. Don't be worried if the highest version is IE10 it means that it applies to IE10 AND above.........
  • Proxmox Breaks Storage/LVM Backing If Killing QEMU-IMG


    I tried to stop a qemu-img copy or clone and it broke everything. It was fine to "stop" it from the GUI but a process still persisted so I killed the relevant qemu-img and the kernel went crazy. It also may not have helped that I tried to lvremove a different volume (an unused disk). But either way it breaks LVM (you cannot even run lvdisplay) so a reboot is necessary. Jan 17 06:45:21 testserver kernel: [ 5680.439337] systemd-udevd D 0&nbs........
  • Debian 9 SSH root password authentication failure password not working problem / solution


    In Debian a lot of times SSH disables the root user to login by password by default. This means you will get an authentication failure as if you typed in the wrong password. The logs also indicate the password is wrong but what is often the case is in the config file Check /etc/ssh/sshd_config cat /etc/ssh/sshd_config|grep -i permitrootlogin Make sure it says: PermitRootLogin yes If not change it and restart SSH........
  • Why SMART is not smart at all and doesn't properly predict disk errors that cause a kernel panic or crash


    Before getting into the output here is my typical experience with SMART, there is what I call a "bad disk" with pending and uncorrectable sectors that cannot be reallocated. It has caused a kernel panic and system crash repeatedly as we can see from the logs. But SMART says it has "PASSED" its self assessment. SMART is still useful to me but it is more about looking at Current_Pending_Sector. Any time I have had anything but 0 for that attribute it........
  • How Does Cisco CUCM (Cisco Unified Communication Manager) Work?


    Cisco's CUCM (Cisco Unified Communication Manager) is a system that combines voice, video, data and mobile products into a single unified management suite. At its core, the CUCMis like a "Super PBX" that controls the flow of all communications through an organization even single or multiple site deployments. Cisco's CUCMmakes communication more effective and simple through centralized management and unification of communications resources.........
  • MySQL Using mytop Debug Source of High IO and Slow Performance


    mytop is one of my favorite tools and it is fairly simple aside from a few caveats and issues that persist to this day. To install it on Centos: yum -y install centos Configure ~/.mytop vi ~/.mytop user=root host=localhost db=test #port=3306 socket=/var/lib/mysql/mysql.sock header=1 color=1 Try runni........
  • systemd management using systemctl and journalctl to check systemd logs


    systemd is like the service manager for your Centos and other modern Linux distributions (including Debian/Mint/Ubuntu) allows you to enable services, stop them, restart them, check their status and even reboot your system. The key commands or arguments you will use with systemctl are the following: Unit Commands: list-units [PATTERN...] List loaded units &nbs........
  • Linux What is umask (user mask) for file and directory creation permissions and how to calculate umask and change the defaults


    umask are the default permissions that are applied when a file or directory are created. To see this in action simply just "touch filename" or "mkdir somedir" and you'll see what default permissions are applied. The first thing Ialways tell people you should know is to NEVER change the defaults unless you are making them more restrictive. But they work well and if you change the defaults you could end up creating a file without permission to read........
  • Linux Permissions and Groups Real Usecase for Group Access


    Ihave a directory structure which the primary user needs full access on but wanted a user to access only a specific directory within the main directory (so they could write in there only and nowhere else). Here's what Idid: [root@compevo8001 dllnow]# ls -alh drwxrwxr-x 2 someuser software 4.0K Oct 19 2017 ExpireYMD-2017-11-20 drwxrwxr-x 2 someuser software 4.0K Nov 19 2017 ExpireYMD-20........
  • Cannot install moodle


    After starting the install it stalls here: admin/index.php?cache=0&agreelicense=1&confirmrelease=1&lang=en If you manually refresh you get a Plugins check screen: Installation System Moodle second step fails just blank screen: https://domain.la/user/editadvanced.php?id=2 Solution: give up and choose something else it shouldn't be thi........
  • gvfs mount in /run/user cannot be accessed or displayed wrong permissions Error: Location is already mounted


    You get errors like below and see you have all question marks for the permissions if you go to /run/user/1000/gvfs If you try to access the mounted share such as anything mounted as gvfs like an SSH share in your file manager you may get an error like this. It generally means an interruption in communication or a fault with gvfsd has caused it. Solutio........
  • Linux bash shell doesn't show username, hostname or current path fix solution


    Usually this is because when you created your user you added a user but didn't create their home directory and/or for some reason your .bashrc and .bash_profile in ~ (home) is broken/missing. In your home just create the following files with the following content to solve it: .bashrc and .bash_profile. To apply it just relogin/start a new bash session # .bash_profile # Get the aliases and funct........
  • zenity popup messages, windows, dialogs, error messages calendars and more howto on Gnome Linux including Ubuntu, Linux Mint, Centos and more


    zenity is a nice utility as part of the gnome window manager that allows you to script from bash and retrieve the input from the user. It could also be helpful in just notifying a user when they login with a popup window. I'll give an overview of what's available with zenity: Application Options: --calendar Display calendar dialog --entry Display tex........
  • VMWare Vsphere VCSA Graphical Install Creates json


    yes it does create its own json ============================================ cat /tmp/vcsaUiInstaller/ovftool-20180809-175238948-20180809-175603497.log |grep -i json 2018-08-09T17:56:04.238-07:00 verbose OVFTool[30966] [Originator@6876 sub=Default] Manifest file entry: SHA1(VMware-vCenter-Server-Appliance-6.7.0.12000-8832884_OVF10-file1.json) = 1deb658c724767697587d5909c4051c01813e6a1 --> ........
  • qemu-img resize howto


    The Correct Way To Resize In Place qemu-img resize kvmuserwindows2008dcetest.img +1G Image resized. Below is a common mistake that some users make they are trying to specify a new image name but it can be resized in place (just make sure the VMis NOT running and you've backed up the data in case something goes wrong). qemu-img resize kvmuser453111.img kvmuser453111-larger.img +5G New i........
  • gmail.com address failing in Postfix


    Aug 10 01:11:54 mailserver postfix/smtp[6180]: 020AE17C2BD1: to=, relay=none, delay=0.29, delays=0.28/0/0/0, dsn=5.4.4, status=bounced (Host or domain name not found. Name service error for name=gmail.con type=A: Host not found) A user complained that their e-mails weren't being delivered but they actually made a small typo and used gmail.con so it wasn't working as expected of course........
  • Debian Mint Ubuntu compiling xmr-stak


    sudo apt-get install libcurl4-openssl-dev git build-essential autotools-dev autoconf libcurl3 sudo apt-get install libcurl4-gnutls-dev git clone https://github.com/wolf9466/cpuminer-multi sudo apt-get install cmake libpthread-* libmicrohttpd-dev libssl-dev libhwloc-dev git clone https://github.com/fireice-uk/xmr-stak-cpu.git make install cd bin chmod +x xmr-stak-cpu ./xmr-stak -O xmr........
  • migration/4 migration 4 is using too much CPU


    top - 13:02:52 up 603 days, 19:19, 2 users, load average: 5.01, 4.15, 3.44 Tasks: 604 total, 5 running, 599 sleeping, 0 stopped, 0 zombie Cpu(s): 17.7%us, 36.1%sy, 0.0%ni, 42.0%id, 4.1%wa, 0.0%hi, 0.2%si, 0.0%st Mem: 16278908k total, 4269684k used, 12009224k free, 119672k buffers Swap: 8k total, ........
  • Linux Mint 18 Screen Goes Dark or Black After Screensaver or even when using the Desktop Solution


    You can search for this bug and it seems like it may be related to ecryptfs and is many years old. The symptoms are that you return to the computer and the screensaver was active or the screen was asleep/black and it doesn't seem to come back. But you check by SSH the computer is running fine and are frustrated you'll lose your running programs and have to reboot. There is a simple solution: Ctrl + Alt + F1 Ctrl +Alt + F8 Ba........
  • VMWare 6.7 VCSA VSphere ESXi Management SSO Install Guide on Linux using the CLI


    #mount the VCSA DVD mount /dev/sr0 /mnt/cd #alternatively you could mount the iso directly mount -o loop vcsa.iso /your/mount/path #for this purpose we are using the CLI installer on Linux cd /mnt/cd/vcsa-cli-installer/lin64 #no it's not going to be that easy you can't just run vcsa-deploy like that you need to use a template or configured .json file ./vcsa-deploy Usage: vcsa-deploy [-h] [--version] [--supported-deploymen........
  • OpenVPN auth-user-pass-verify ENV script error


    Starting with newer versions of OpenVPN Ibelieve 2.2+ you need to have "script-security 3" set or you can't execute a third party script. Prior to that you could also use the auth-user-pass-verify like this: auth-user-pass-verify ./validate.pl "$username $password $ip" via-env Options error: the --auth-user-pass-verify directive should have at most 2 parameters. To pass a list of arguments as one of the paramete........
  • Cannot create gradle for conversations


    The main issue is it looks like Java is not configured to accept the invalid ssl cert that is coming from the download location. Exception in thread "main" java.lang.RuntimeException: javax.net.ssl.SSLException: java.security.ProviderException: java.security.InvalidKeyException: EC parameters error export ANDROID_HOME=/home/user/Downloads/tools/ Conversations-master$ ./gradlew Downloading https://services.gradle.org/distributions/grad........
  • not allowed to execute '/usr/bin/apt-get install eclipse' as root linux sudo user permisson issue and solution


    This is most likely to happen on a normal GUI system like Ubuntu or Linux Mint. If you or the user is meant to have sudo / root privileges it is as simple as editing the following files: Now assume your username is "iamtheuser" vi /etc/group adm:x:4:syslog,iamtheuser sudo:x:27:anotheruser,iamtheuser Find the above lines and add a comma and "ia........
  • Database Error One or more of the WHMCS database tables appear to be either missing or corrupted. Please check and repair. - WHMCS Solution


    Database Error One or more of the WHMCS database tables appear to be either missing or corrupted. Please check and repair. This error can be misleading especially if you know you are using a known good backup or restoration of the WHMCS database. The error can also be that the user lacks permissions to read and write to the database. To check to this in MySQL shell: GRANT read,write to dbusername@localhost on dbna........
  • postfix errors fatal: no SASL authentication mechanisms /usr/libexec/postfix/smtpd: bad command startup -- throttling solution


    Jul 3 22:12:17mailserver postfix/smtpd[6195]: fatal: no SASL authentication mechanisms Jul 3 22:12:18mailserver postfix/master[4881]: warning: process /usr/libexec/postfix/smtpd pid 6195 exit status 1 Jul 3 22:12:18mailserver postfix/master[4881]: warning: /usr/libexec/postfix/smtpd: bad command startup -- throttling This only ever happens in my experience when the authentication method is actually Dovecot. Usually the problem........
  • mail command line examples of how to send an email using Linux / Unix and the Bash Shell or Scripting


    A simple way that may work for a lot of people who just need basic output for their scripts or daemons to announce an action is this: echo "body or message" | mail -s "realtechtalk.com" user@domain.com If you want to send a text file as the body just do this instead: mail -s "realtechtalk.com" user@domain.com < /tmp/sometxtfile.txt These are some ve........
  • Maximum number of connections from user+IP exceeded (mail_max_userip_connections=10) Dovecot Solution


    This happens because Dovecot limits the maximum IMAPconnections per IPto just 10. This may be fine for a single client side IPbut if an entire office or multiple users are behind one IPor a single heavy user is active then you will get bizarre errors in your e-mail clients such as "Password Incorrect" or similar in Thunderbird. It won't be obvious on the client side as to what the problem is and they will probably just think the server is misconfi........
  • No comments are allowed here Internal Server Error The server encountered an internal error or misconfiguration and was unable to complete your request.


    Internal Server Error The server encountered an internal error or misconfiguration and was unable to complete your request. Please contact the server administrator, root@localhost and inform them of the time the error occurred, and anything you might have done that may have caused the error. More information about this error may be available in the server error log. Apache/2.2.15 (CentOS) Server at testdomain.com Port 80........
  • Linux Mint Black Screen after boot no graphics solution


    This is not the normal "black screen"issue and I was shocked to eventually find out why. The normal advice of reconfiguring Xorg didn't work. Even booting into "Recovery Mode" did not help. Here is the short end of the stick that fixed it: sudo apt-get install mdm mate-desktop-environment Yes you got it right, mdm and the mate-desktop-environment / gnome were somehow uninstalled. This must be whe........
  • Mozilla Firefox Address Bar History Not Working places.sqlite corruption solution database repair


    Here is the only solution Ifound that works in Firefox: *Note you could basically just copy all of the commands in bold (the rest just shows the output) Install sqlite3 sqlite3 places.sqlite sqlite> .clone places.sqlite-fixed moz_places... done moz_historyvisits... done moz_inputhistory..........
  • sign_and_send_pubkey: signing failed: agent refused operation - SSH Solution


    sign_and_send_pubkey: signing failed: agent refused operation This happens when you don't manually add your ssh key with ssh-add it is some weird new feature in SSH or Ubuntu/Debian that causes this weird problem. Solution: ssh-add Identity added: /home/user/.ssh/id_rsa (/home/user/.ssh/id_rsa)........
  • How To Set or Change Useragent in Firefox and Seamonkey


    In your browser go to "about:config" Right click and choose "New" ->"String" The name should be: general.useragent.override String Value: Mozilla/5.0 (Linux; U; Android 2.2.1; en-ca; LG-P505R Build/FRG83) AppleWebKit/533.1 (KHTML, like Gecko) Version/4.0 Mobile Safari/533.1 You don't even have to restart to make this work.........
  • solution mysqldump: Got error: 1044: Access denied for user 'user'@'localhost' to database 'thedb' when using LOCK TABLES


    It is simple the user just needs to be given the "LOCK TABLES" privilege. As root run this command: GRANT LOCK TABLES ON yourdatabase.* TO yourmysqluser@localhost;........
  • MySQL How To Grant Access To ALL Databases For Export and Backup Purposes


    GRANT SELECT, LOCK TABLES ON *.* TO yourmysqluser@localhost; All you need to do a full MySQL dump on all databases is the SELECT and LOCK TABLES privileges. This way you don't have to use the mysql root user. Data could be compromised this way but at least no harm from manipulation, changes or deletion are possible by locking down the privileges to the minimum for a full MySQL dump and backup.........
  • error: Could not locate RPC credentials. No authentication cookie could be found, and no rpcpassword is set in the configuration file Bitcoin Litecoin Error


    error: Could not locate RPC credentials. No authentication cookie could be found, and no rpcpassword is set in the configuration file This is usually because the .cookie file cannot be read by the user you are running Litecoin or Bitcoin client/daemon as. You can adjust the permissions of the file so that the user or group they are apart of has read permissions. ........
  • Installing SSL Certificate with Chain Intermediary CA File


    Some of the cheaper or newer SSL suppliers will require this to work properly (otherwise you may be prompted that the cert is invalid when it's not the case but it will certainly scare off your users!). In the Apache vhost conf for the domain here is what you add: SSLCACertificateFile /path/to/your/cafile.pem Here is a full example of an SSL Vhost config in Apache using a CA Certificate file ........
  • How to start screen in bash script or from /etc/rc.local on startup as a specific user


    It takes some tinkering the main thing is that the "-dmS" flag allows screen to start without a session which of course sudo won't have. solution: /usr/bin/sudo -u user /usr/bin/screen -dmS nameyouchoose /script/start.bash this doesn't work at all: /usr/bin/sudo -u user "/usr/bin/screen /script/s........
  • Linux How To Clone One System Harddrive to another remote system


    The easiest way is to use SSHand DD or a combination of netcat. SSHwill be a little slower due to encryption but is the most secure way (on two older systems the average clone speed is about 40-50MB/s). This is also OS independent as it doesn't matter what the source OS is because you are literallly cloning the drive so you retain the partition table and settings. Clone HDD using SSH and DD........
  • MySQL Cannot Update/Write to any database table solution


    This happened on Centos for no apparent reason with no obvious issue in the logs. Data could be read fine but not written (possibly due to some corruption or out of memory issue in the OpenVZ container is the best guess). All mysql update and insert queries failed freezing without any error log on any database and table. Tried to restart: service mysqld restart Timeout error occurred trying to stop MySQL........
  • mysql how to reset passwords with a few commands


    The commands below will help you reset any mysql user password. use mysql; update user set password=PASSWORD('thenewpass') where User='theusername'; flush privileges; The first line says to use the "mysql" database which contains all the user info. the second update line sets the new password "thenewpass" for the u........
  • How To Create Apache htpasswd file


    This just simply outputs what you need a username and password that can be used to authenticate from .htaccess htpasswd -nb user password user:Gnb6uE9Lp4gt2 If you want to write it straight to a file htpasswd -cb /tmp/somefile.pw user password How To Use This In .htaccess AuthUserFile /tmp/somefile.pw AuthName GetLost!! AuthType B........
  • Authentication refused: bad ownership or modes for directory /home/user SSH Public Key Authentication Failed Solution


    First of all I got this error after accidentally messing up my usergroup by using usermod -G user group When I would login using SSHkeys it would fail: sshd[2020]: Authentication refused: bad ownership or modes for directory /home/one No worries, the fix is simple! chmod g-w /home/use........
  • cannot mount kvm ntfs image


    guestmount -a kvmuserscra.img -m /dev/sda1 mount libguestfs: error: mount_options: /dev/sda1 on / (options: ''): mount: unknown filesystem type 'ntfs' guestmount: '/dev/sda1' could not be mounted. guestmount: Did you mean to mount one of these filesystems? guestmount: /dev/sda1 (ntfs) guestmount: /dev/sda2 (ntfs) yum -y install ntfs-3g still........
  • responsive table without changing much code solution


    So you've got a responsive site with tables but it breaks them so anything not viewable on the screen is now cut off. Here is a simple solution that will allow users to scroll horizontally so they can see the whole table: &........
  • userdel user userdel: cannot lock /etc/passwd; try again later.


    I am not sure why this happened I think it's because the file was in use by another duplicate process or script. userdel user userdel: cannot lock /etc/passwd; try again later. ........
  • M2Crypto.SSL.Checker.WrongHost: Peer certificate subjectAltName does not match host, expected fedora-archive.ip-connect.vn.ua, got DNS:mirror.ip-connect.vn.ua


    You are using Centos 5 which is deprecated so nothing in yum will work until you follow this post to use the vault: http://realtechtalk.com/Centos_59_Working_Vault_Repo_file-1921-articles yum update Loaded plugins: fastestmirror Loading mirror speeds from cached hostfile * epel: fedora-archive.ip-connect.vn.ua Traceback........
  • linux cp and mv will not overwrite due to alias!


    This through me for a loop when I would do a cp -rf or mv -f nothing would get overwritten even if piping y or yes to the command. Type alias and you'll see why: alias cp='cp -i' alias l.='ls -d .* --color=auto' alias ll='ls -l --color=auto' alias ls='ls --color=auto' alias mv='mv -i' alias rm='rm -i' The -i is a safeguard against messing things up but however does mess things up worse when you know what........
  • kdenlive - No LADSPA plugins were found! Check your LADSPA_PATH environment variable. [producer_xml] failed to load transition "qtblend"


    This happens if you are running a kdenlive script from the shell of a remote machine without using SSH "-X" forwarding and it will also cause any areas where you write text to be a white screen for that duration. melt FusionFestival.kdenlive No LADSPA plugins were found! Check your LADSPA_PATH environment variable. [producer_xml] failed to load transition "qtblend" [producer_xml] failed to load transition &q........
  • /usr/bin/supermin-helper exited with error status 1. To see full error messages you may need to enable debugging. See http://libguestfs.org/guestfs-faq.1.html#debugging-libguestfs at /usr/bin/virt-list-partitions line 177.


    virt-list-partitions kvmusertest.img /usr/bin/supermin-helper exited with error status 1. To see full error messages you may need to enable debugging. See http://libguestfs.org/guestfs-faq.1.html#debugging-libguestfs at /usr/bin/virt-list-partitions line 177. #solution update-guestfs-appliance........
  • Centos 5.9 Working Vault Repo file


    Centos 5 is not supported running yum will produce an error like this: YumRepo Error: All mirror URLs are not using ftp, http[s] or file. Eg. Invalid release/ removing mirrorlist with no valid mirrors: /var/cache/yum/base/mirrorlist.txt Error: Cannot find a valid baseurl for repo: base Solution - Update this file CentOS-Base.repo # CentOS-Base.repo........
  • How to backup entire computer Linux Mint Ubuntu with tar


    sudo tar --ignore-failed-read -czvf mycomputer-backup.tar.gz --exclude=/home/otheruser/* --exclude=/proc/* --exclude=/sys/* / Note the --exclude clauses and modify/add according to your needs........
  • tar how to ignore failed reads and not exit


    This is an important feature a failed read can genuinely occur if a temporary file has been removed or if you try backing up a sysetm file in /proc /sys (which you shouldn't really anyway). The way to fix this is the following switch: --ignore-failed-read Example: sudo tar --ignore-failed-read -czvf mycomputer-backup.tar.gz --exclude=/home/otheruser/* --exclude=/proc/* --e........
  • kdenlive titles/text renders as white screen when using .sh script


    When using the .sh script the rendering doesn't work after an upgrade of related packages to kdenlive. kdenlive (kdenlive:amd64 (4:17.04.1+git201705191233~ubuntu16.04.1)) with affine or composite transitions was fine but is now broken during the time of transition it is just a white screen. The previous version was fine: kdenlive:amd64 (4:17.04.1+git201705191233~ubuntu16.04.1 But now I can't find it or install it:........
  • Wine uninstalled broken on Linux Mint


    Solution: Aptitude is very smart and fixed the issues it was because of nvidia cuda and opencl and nothing else suggested or hinted this using apt sudo aptitude install wine The following NEW packages will be installed: ocl-icd-libopencl1{ab} ocl-icd-libopencl1:i386{ab} wine wine1.6 wine1.6-amd64{a} wine1.6-i386:i386{a} The following packages will be REMOVED:........
  • ffmpeg trouble concatenating similar but different files


    When things go wrong your video is basically unplayable or the first video plays fine and then freezes when moving on to the next. Generally if both videos weren't produced with the exact 100% same settings you will have issues. You can try the basic concat but it often won't work right. Solution for me: My example uses 3 videos in total so "n=3" and a=1 to include audio. ffmpeg -threads 12 -i file1.mp4 -........
  • ffmpeg Unable to Use Hardware Encoding with Nvidia 3.40 Driver and GT210 card


    I believe from what I've read that this card's driver doesn't support the features after trying all known troubleshooting methods. ffmpeg -i uservideoRendered.mp4 -filter:v hwupload_cuda,scale_npp=w=1920:h=1080:format=nv12:interp_algo=lanczos,hwdownload -c:v hevc_nvenc -profile main -preset slow -rc vbr_hq -c:a copy uservideoRendered.mp4-test ffmpeg -i uservideoRendered.mp4 -filter:v hwupload_cuda,scale_npp=w=1920:h=1080:format=nv12:interp_algo=lanczos,hwdownload........
  • Linux Mint USB Kernel Tainted and Locked Port/Dev File


    Essentially a program I was running for mining did not terminate properly with Ctrl+C it is listed as defunct and cannot be killed, kernel is tainted and normal tricks to disable the port are impossible the dev and sys entries for the device cannot be browsed or interacted with in any form without a lockup of the request. The only solution is to reboot due to the kernel taint as far as I can find so far. [1130246.811056] INFO: task minerd:21861 blocked for more th........
  • Migrate Centos 7 from Single HDD to mdadm RAID 10 array:


    Done on Centos 7.3 very important as clearly based on older guides it was a lot easier and more simpler! Hint do not use grub2-install! If you have trouble booting after this check this CentOS mdadm RAID booting/fixing guide. One huge caveat if you are an oldschool user or sysadmin who has avoided UEFIbooting The nor........
  • How to change reserved blocks in Linux partition


    user@box:~$ sudo tune2fs -l /dev/md99 [sudo] password for user: tune2fs 1.42.9 (4-Feb-2014) Filesystem volume name: Last mounted on: /mnt/md50 Filesystem UUID: 976a8655-2619-4587-878c-dab07f7b7652 Filesystem magic number: 0xEF53 Filesystem revision #: 1 (dynamic) Fi........
  • rsync run as root sudo without password


    This is a common issue, what if a issue shouldn't have root but you want to use that user to make a full backup of a system? They of course need root access. You can actually just give them passwordless sudo access to rsync in /etc/sudoers: sudo vi /etc/sudoers yourusername ALL = NOPASSWD: /usr/bin/rsync Here is how you would execute rsync: The key thing for the remote host is to........
  • process_usershare_file: stat of /var/lib/samba/usershares/dump failed. Permission denied - samba error solution


    [2017/06/12 21:14:04.991169, 0] ../source3/param/loadparm.c:3259(process_usershare_file) process_usershare_file: stat of /var/lib/samba/usershares/dump failed. Permission denied Issue was the parent directory needed chmod 755........
  • Openshot 2.2 is very unstable always crashing in Linux Mint 18.1!


    Jun 1 15:45:42 videoeditor-desktop org.mate.panel.applet.MintMenuAppletFactory[1882]: project_data:INFO Missing folder chosen by user: Jun 1 15:45:42 videoeditor-desktop org.mate.panel.applet.MintMenuAppletFactory[1882]: project_data:INFO Removed missing file: MAH02949.MP4 Jun 1 15:45:57 videoeditor-desktop org.mate.panel.applet.MintMenuAppletFactory[1882]: ui_util:WARNING Icon theme media-playback-start not found. Will use backup........
  • Track 01: 34 of 1726 MB written (fifo 100%) [buf 99%] 3.6x.Errno: 5 (Input/output error), write_g1 scsi sendcmd: cmd timeout after 1.897 (40) s CDB: 2A 00 00 00 44 A9 00 00 1F 00 resid: 6144 cmd finished after 1.897s timeout 40s write track da


    These errors believe it or not are simply because of not being the root user or running with sudo! However if you didn't know to try as root you'd think there was a problem with your burner or disc Essentially it looks like without root you cannot send the required scsi commands to continue writing. Ithink cdrecord should have built-in tests or safeguards to see if it has the permissions to run the required commands. I guess for more advanced users the idea is simila........
  • MySQL Add multiple IPs for remote user including root howto


    To grant the IP 192.168.2.4 to user mysqlguy GRANT ALL ON *.* TO 'mysqlguy'@'192.168.2.4'; To allow any IPfor mysqlguy just use the wildcard % character GRANT ALL ON *.* TO 'mysqlguy'@'%'; Also note it is normal and fine to have multiple entries in the mysql table.........
  • cPanel error Access denied for user 'root'@'localhost' when adding remote MySQL IP address solution


    Error while connecting to MYSQL: (XID 4ea7s9) Access denied for user 'root'@'localhost' (using password: YES) at /usr/local/cpanel/Cpanel/Mysql.pm line 181 Solution This error occurs because the /root/.my.cnf has the wrong/outdated password for MySQL root user. Simply edit /root/.my.cnf with the correct user. This normally happens if you update outside of cPanel.........
  • phpBB3 slow and internal dummy connection


    Using Apache 2.2 and PHP5.6 PHPBB3 is very slow to respond. Actually for some reason it takes so long to even register a log entry in access_log as in several seconds or a few minutes later it shows up in Apache. All other vhosts and Apache access stops working and freezes until the request to access PHPBB3 slowly completes. It seems to randomly be slow if you stop using it whether for posting or reading the forums. I've migrated to different machines including........
  • ssh forward multiple ports in the same connection and command even works with NAT!


    You can actually just pass multiple "-L" statements to achieve this. An example is as below: ssl -L 80:192.168.10.5:80 -L443:192.168.10.5:443 -L2068:192.168.10.5:2068 -L 8192:192.168.10.5:8192 user@remotehost.com The above essentially is saying forward ports 80,443,2068,8192 to the remote IPof 192.168.10.5 (even though it is behind NAT). Essentially SSH will do the NAT part even if the........
  • Avocent DSR8020 KVM/IP - Network Connect Error - Solution


    This error is commonly due to Java security or TLS settings but there is a second issue with forwarded ports that also causes it. 1. Java Security/TLS Settings issue: This article has the solution to change them all in Linux automatically 2. Port Forwarding Issue if your Avocent DSR is behind NAT/private IP........
  • ecryptfs errors


    ecryptfs-mount-private Enter your login passphrase: Inserted auth tok with sig [ee16d84] "into the user session keyring mount: No such file or directory" [ 156.118113] ecryptfs_mount: kern_path() failed [ 156.118431] Reading sb failed; rc = [-2] [ 164.233055] traps: mate-notificati[3472] trap int3 ip:7f43d7002c13 sp:7fff162c6600 error:0 [ 166.017061] ecryptfs_mount: kern_path() failed........
  • Migrating from Linux Mint 17.2 mdadm RAID array to a new one (because I upgraded to larger drives).


    1.) Replicate the number of partitions in your new drives. gdisk /dev/sda gdisk /dev/sdb I created 3 partitions of the same same size. partition #1: +1G (/boot) partition #2: +60G (swap) partition #3: rest of it (/) #note if you are using GPT/gdisk you need to create separate a partition at least 1MB in size (in my case I would a 4th partition and mark it type ef02).........
  • root/home directory has ownership changed to the wrong user/owner mysteriously


    Ifigured out what caused this but don't have the solution just yet. Iwould deploy a certain script from a .tar.gz to some servers and found that /root was always owned by user and group "1000.1000". This corresonded to the user who made the .tar.gz. For some reason when extract normally with "tar -zxvf file.tar.gz" it impacts the parent directories ownership. There must be some recursion going on or possibly the .tar.gz but I haven't f........
  • DRBD Split-brain solution


    Uh oh [17925926.174277] block drbd0: Handshake successful: Agreed network protocol version 96 [17925926.174325] block drbd0: conn( WFConnection -> WFReportParams ) [17925926.174342] block drbd0: Starting asender thread (from drbd0_receiver [1682]) [17925926.174432] block drbd0: data-integrity-alg: [17925926.174581] block drbd0: drbd_sync_handshake: [17925926.174586] block drbd0: self 2AAE66AF9252D6DB:2815BF........
  • How to Properly Secure SSL/TLS Apache Settings against Heartbleed Poodle (TLS) Poodle (SSLv3) FREAK BEAST CRIME


    Many users still are not aware but simply patching OpenSSL does not secure you against many known and easy to exploit attacks that will render your encryption useless by an attacker. Use the following setings in /etc/httpd/conf.d/ssl.conf SSLCipherSuite "EECDH+ECDSA+AESGCM EECDH+aRSA+AESGCM EECDH+ECDSA+SHA384 EECDH+ECDSA+SHA256 EECDH+aRSA+SHA384 EECDH+aRSA+SHA256 EECDH EDH+aRSA !CAMELLIA !SEED !3DES !RC4 !aNULL !eNULL !LOW !MD5 !EXP !PSK !........
  • K9 Mail Android Cannot See or View E-mails Disappear after reading - with Dovecot server. Solution


    This actually only happened after an e-mail server ran out of space due to run away log files. Normal Desktop clients were not affected. It appeared to be a bug in K9 mail but even reinstalling/wiping all settings did not fix it (read e-mails would still not reappear). This is moreso a bug in Dovecot where it probably messes up the index files. How do you fix this in Dovecot/your e-mail server? You need to delete the do........
  • ERROR 2013 (HY000): Lost connection to MySQL server during query


    The solution is simple but strange, if you copy your /var/lib/mysql directory to another server and think it will work, be sure to check if you have /var/log/mysql and binary log files. If you do, the server will not work and will give you errors like below and crash without the proper log files. UPDATE user SET password=password("newpass") WHERE user='root'; flush privileges; ERROR 2013 (HY000): Lost connection to MySQL server durin........
  • MySQLD Server shutdown remotely unexpectedly


    170110 5:35:23 [Note] /usr/libexec/mysqld: Normal shutdown 170110 5:35:23 [Note] Event Scheduler: Purging the queue. 0 events 170110 5:35:23 InnoDB: Starting shutdown... 170110 5:35:24 InnoDB: Shutdown completed; log sequence number 0 12765401 170110 5:35:24 [Note] /usr/libexec/mysqld: Shutdown complete 170110 05:35:24 mysqld_safe mysqld from pid file /var/run/mysqld/mysqld.pid ended........
  • MySQL Allow Access from Remote Host IP and Update All Users


    Change Host="192.168.5.99" with the remote IP allowed(this is of course more secure but also cumbersome if your IP changes). You could also have a single layer of protection that specifies the IP via firewall or both (of course both are far mor secure). UPDATE user SET Host="192.168.5.99" where Host="localhost" or for any/wildcard UPDATE user SET Host="%" where Host="localhost&qu........
  • ADATA SU800 256GB 3D NAND Flash SSD Test & Review


    I keep reading these drives are slower, but they are cheap and still SSDand work very fast for my needs. As you can see the sequential read is 481-491MB/s, if I put them in MDADM RAID10 mode (normal RAID1) they should give me well over 900MB/s and with redundancy and being very cheap for what they offer. [1232206.315622] scsi 8:0:1:0: Direct-Access ATA ADATA SU800&........
  • remove gpt partition linux


    sudo fdisk /dev/sdh WARNING: GPT (GUID Partition Table) detected on '/dev/sdh'! The util fdisk doesn't support GPT. Use GNU Parted. WARNING: The size of this disk is 8.0 TB (8001563221504 bytes). DOS partition table format can not be used on drives for volumes larger than (2199023255040 bytes) for 512-byte sectors. Use parted(1) and GUID partition table format (GPT). The device presents a l........
  • DRBD Slow Performance - 99.99 % [jbd2/drbd0-8] highiowait solution


    Tired of checking iotop and seeing that your drbd partition is using 99.99% of io all the time and finding your drbd device performs slow in general? This is especially an issue in versions of DRBD in the 8.3 tree in particular one documented case is on "8.3.13" but it likely applies to other devices. The symptoms are that resyncing is fine and normal but any reasonable amount of activity is very slow and lagged and creates a high server load and con........
  • weird mv error mv: inter-device move failed:


    mv -f /home/user/Downloads/android-studio/ /mnt/sda3/ mv: inter-device move failed: ‘/home/user/Downloads/android-studio/’ to ‘/mnt/sda3/android-studio’; unable to remove target: Is a directory........
  • OpenVZ Error: Failed to load 2nd level quota solution


    Syncing private Live migrating container... Syncing 2nd level quota 11000: invalid option -- F Usage: vzdqload quotaid [-c file] commands Loads user/group qouta information from stdin into quota file. -c file use given quota file Commands specify what user/group information to load: -G grace time -U disk limits........
  • Cannot Read License File cPanel Solution


    This can happen because port 80 is not open, or your license has expired and/or your IP is out of date and also if the license server itself from cPanel is having issues. In most cases as long as you have a valid license the following command will solve it: /usr/local/cpanel/cpkeyclt Updating cPanel license...Done. Update succeeded. Building global cache for cpanel...Done Cannot........
  • openvpn 2.3.10-1.el6 issues auth-env does not work correctly for auth-user-pass-verify


    openvpn 2.3.10-1.el6 issues in the .conf auth-user-pass-verify "passwordcheck $username $password $untrusted_ip" via-env auth-env does not work correctly in OpenVPN 2.3: Sat Apr 23 02:30:22 2016 - $username - $untrusted_ip - login failure But OpenVPN 2.2 does work as expected. It could be that the specified script automatically receive........
  • Linux Mint/Ubuntu/Debian Window Controls Missing Solution


    If Linux Mint 17 or other has no window buttons/controls you can do the following from terminal: marco --replace& Sometimes it can be fixed if you go to your themes/appearance and choose a new one but in the case like mine where Compiz is installed but not running/working then that fix will not work and will require the marco command above. What if you can't type in a terminal Window? If you close........
  • Linux Mint/Ubuntu/Debian Dual NICs networks problem when enabling and disabling one device


    The Scenario You have dual NICs and you disable NIC1 which uses 192.168.1.1 as its gateway. With NIC2 you enable it/connect it to another network which also has the gateway 192.168.1.1 Everything will work fine at this point. When switching back to NIC1 even with NIC2 disabled and even unplugged, the OS basically can't pick up the new/updated ARP entry of the old device for 192.168.1.1 and perhaps thinks it is a security risk or spoof of some sorts and blocks i........
  • Errors were found while checking the disk drive for /.


    Iwill start by saying I think I know what caused this boot-time error on Linux Mint but should also apply to Debian and Ubuntu. I changed my BIOS time to several hours in the past to match the current time, but this caused Linux to think there were incorrect filesystem times. The problem is that it seems when you hit this I am not sure what is happening, it doesn't seem to be doing fsck and hangs without prompting the user. What I have found is that........
  • Debian Ubuntu Mint Samba Share config file location


    /var/lib/samba/usershares But note that it is just simple file sharing if you need directory mask, create mask etc... you still need to edit the smb.conf file to create your share. Here is an example file: comment= usershare_acl=S-1-1-0:R,S-1-22-1-1000:F guest_ok=y sharename=BabyPhotos........
  • Debian Linux Ubuntu Mint connect to pptp from terminal bash shell


    apt-get install pptp-linux echo "yourvpnusername * yourpasspass *" >> /etc/ppp/chap-secrets vi /etc/ppp/peers/provpnaccounts.com enter (ignore the lines): ============ pty "pptp server.provpnaccounts.com --nolaunchpppd" name testuser #remotename PPTP require-mppe-128 file /etc/ppp/options.pptp ==========........
  • Mount a SMB Samba share in fstab Linux Debian/Ubuntu/Centos


    Add the following to fstab where 192.168.1.125/Media is the samba share and where /home/homeuser/Downloads is where you want to mount. Change user and pass to what is needed (if no pass is required it still works fine with the below). //192.168.1.125/Media /home/homeuser/Downloads cifs user=guest,pass=bla 0 0 mount: wrong fs type, bad option, bad superblock on //192.168.1.125/Media, &nbs........
  • Avocent 8020 KVM Java Icedtea Viewer


    This command in Debian/Ubuntu/Mint will get everything need installed for most Java based KVM viewers: sudo apt install icedtea-netx The following additional packages will be installed: ca-certificates-java icedtea-netx-common openjdk-8-jre openjdk-8-jre-headless It seems every other updated version of Java or Icedtea breaks things and I will save the frustration of Java for another post.........
  • Cannot get mono to work properly on Linux Mint


    mono/wine not working in Ubuntu/Linux Mint/Debian: The assembly mscorlib.dll was not found or could not be loaded. It should have been installed in the `/usr/lib/mono/2.0/mscorlib.dll' directory. solution: sudo apt-get install mono-complete Problems: mono does not work well for even simple things like a Winrar self extracting .exe fi........
  • Centos 6 how to guide convert LVM non-RAID into mdadm 1/10 RAID array live without reinstalling


    Here is the scenario you or a client have a remote machine that was installed as a standard/default minimal Centos 6.x machine on a single disk with LVM for whatever reason. Often many people do not know how to install it to a RAID array so it is common to have this problem and why reinstall if you don't need to? In some cases on a remote system you can't easily reinstall without physical or KVM access. So in this case you add a second physical or disk or already ha........
  • Centos cannot login by console or ssh session closed immediately


    In my case I could login with the initial install but I rsync'd everything over while preserving ownership and permissions to another RAID partition and booted from that.was fine before. The problem is that you are kicked out the second you login and the problem was SELINUX for some reason (perhaps it noticed something strange when it was moved to the new partition) login: pam_unix(login:session): session opened for user root by LOGIN(uid=0) login: ROOT LOG........
  • Linux sudo config sudoers to run command without a password howto


    Before reading on remember to put the line at the bottom of /etc/sudoers as from experience what happen is that other rules cancel out what you have added. If your sudoers setup is correct it will work immediately upon saving without requiring a reboot. Edit /etc/sudoers yourusername ALL = NOPASSWD: /path/to/command *Once again remember the above should be on the bottom of the sudoers file or........
  • ONVIF Linux Security Camera Setup


    First of all this seems to apply to many ONVIF devices Hard coded IP: 192.168.1.10 (yes not kidding no DHCP!) 00:12:12:9C:C2:00 To view RTSP stream use VLC, or openRTSP or other RTSP capable software: rtsp://192.168.1.10/user=admin_password=tlJwpbo6_channel=1_stream=0.sdp user: admin password: blank http://ip/Login.htm Uses Quicktime and is a poor quality picture and slow Cannot change pass........
  • Installing zoneminder on Ubuntu/Debian Linux Howto


    sudo apt-get install zoneminder [sudo] password for one: Reading package lists... Done Building dependency tree Reading state information... Done The following packages were automatically installed and are no longer required: libuser-perl python-evince kdebase-apps kwrite unixodbc libgnomeprint2.2-data python-soappy vgabios python-metacity hddtemp python-mediaprof........
  • Lost connection to MySQL server during query [2013]


    This happened while trying to delete several thousand users from phpBB and basically corrupted the innoDB tables. InnoDB: Page lsn 3 881164362, low 4 bytes of lsn at page end 881164362 InnoDB: Page number (if stored to page already) 86920, InnoDB: space id (if created with >= MySQL-4.1.1 and stored already) 0 InnoDB: Page may be an index page where index id is 700 InnoDB: (index "tid_post_time" of table "phpBBdb2005"."phpbb3_p........
  • PHP Issues with Joomla Strict Standards: Non-static method JLoader::import() should not be called statically


    This is basically caused by upgrading PHPto a new version like 5.4 when you had 5.2 before and an old version of Joomla. The only solution is to upgrade Joomla or downgrade PHP, both of which can be a pain. Strict Standards: Non-static method JLoader::import() should not be called statically in /home/userdir/public_html/libraries/joomla/import.php on line 29 Strict Standards: Non-static method JLoader::register() should not be ca........
  • Vbox/Virtualbox devices grayed out for non-root user solution


    It is a permissions issue that is hard to fix. All but one USB device is greyed out. I am already a member of "vboxusers" I have already enabled and disabled USB support for the guest. I have already reinstalled the latest VBOx guest editions If running as root it all works fine Changing........
  • libguestfs tools howto guide for mounting partitions and managing virtual machine images


    libguestfs tools howto guide for managing virtual machine images. libguestfs-tools aka guestfs tools has a lot of tools that make this very easy for you. You can easily mount partitons from an image with some of the commands below. To mount a partition #mount the kvmuser102821.img image and the /dev/sda1 partition from it to the local directory "mount" guestmount -a kvmuser102821.img -m /dev/sda1 mount ........
  • /usr/libexec/mysqld: The table 'session' is full solution


    First of all if you're getting this error it is a result of extreme database activity. If you aren't expecting it or it doesn't make sense to you 99% of the time this is a database driven script being exploited (some common examples I see often are things like phpBB being hit by dozens, hundreds or thousands of bots making constant DB write requests). The easiest way to identify this is to restart MySQL and then run the third party tool "mtop" and you'll see all........
  • Postfix how to secure outgoing authenticated e-mails for privacy and hide the IP address, mailer and other things


    The most common solution is to use the /etc/postfix/header_checks but this is a big problem. Why is header_checks a problem? Because it does it to all mail whether incoming or outgoing and whether authenticated or not. We of course want as much header information for incoming as we can get for many reasons but many organizations want to secure and make their mail clients as secure as possible. I adapted this solution to the client's custom config, they are configur........
  • Stop Wordpress new user notification how-to


    It's just a simple plugin that you get from here. After that you can stopped having a barrage of annoying e-mails from WP:)........
  • CPanel Link to all of the command line options


    CPanel says you can access 98% of the functions through CLI which experienced Unix/Linux admins prefer for simplicity and for scripting.  I've never found CPanel easy to use from the admin panel, it seems everything is hard to find and a simple task becomes a series of hunts. So for people like me here's the list: http://cpanel.net/system-administrators/command-line-scrip........
  • phpBB create new email hash manually when modifying or adding user manually directly through MySQL


    Many may ask why would you need to do this? When upgrading from phpBB 2 to 3 the conversion does not keep the admin user you create. If your old admin user has an email address associated that no longer works or is accessible this makes it impossible to reset the admin password. Some may just say "I'll just manually edit the e-mail address" but it won't work and phpBB will fail to find that user if you don't update the "user_email_hash" field but how do........
  • SolusVM error error: Failed to create domain from /home/kvm/kvm101/kvm101.xml error: cannot open file '/dev//dev/kvmcontainer/kvm101_img': No such file or directory


    error: Failed to create domain from /home/kvm/kvm101/kvm101.xml error: cannot open file '/dev//dev/kvmcontainer/kvm101_img': No such file or directory This is caused by what we consider a quark in SolusVMthat Ihelped a client with. SolusVMhas as config for the "LVMvolume name" and does not enforce any convention. Naturally most technical people would use the actual path eg "/dev/kvmcontainer". However th........
  • drbd 8.3 hard drive failure recovery example


    drbd 8.3 hard drive failure recovery drbdadm attach r0 DRBD module version: 8.3.10 userland version: 8.3.8 you should upgrade your drbd tools! 0: Failure: (119) No valid meta-data signature found. ==> Use 'drbdadm create-md res' to initialize meta-data area. ........
  • drbd won't create device if previous partition is on it Command 'drbdmeta 0 v08 /dev/md160 internal create-md' terminated with exit code 40


    This is what fixed it: [root@box13 ~]# dd if=/dev/zero of=/dev/md160 bs=512 count=500 Basically you need to wipe out more than just the 512 byte partition table so 512 bytes * 500 is more than enough to make DRBD happy and think the partition is now empty. The reason this happens is because it gets confused when there is a previous partition with data on the device you are using. root@box13 ~]# d........
  • Wordpress Security Hole, Plug it by manually installing themes and plugins


    It's always bothered me how Wordpress basically forces the user to provide their hosting credentials to install themes and plugins. How do know for sure the data is not being saved, intercepted and being provided backdoor access to the NSA or other agencies or even just being misused by others with access? Here's how to close the security hole above and if you're already given Wordpress your credentials make sure you change everything associated it with it. Eg. change your........
  • LVM Tutorial how to create a Physical Volume (PV), Volume Group (vg), and a Logical Volume (LV) within it


    # first we need a physical volume which we use the pvcreate tool to create # I create mine on /dev/sdb3 pvcreate /dev/sdb3 dev_is_mpath: failed to get device for 8:19 Physical volume "/dev/sdb3" successfully created # pvdisplay shows the newly created volume pvdisplay "/dev/sdb3" is a new physical volume of "1.35 TiB" --- NEW Physical volume --- PV N........
  • Howto Convert Xen Image to KVM


    #count=10000 makes an image of 10000MB make sure your image is at least the same as your existing dd if=/dev/zero of=yourimage.img bs=1M count=10000 # losetup -fv newimage.raw # fdisk -cu /dev/loop0 # kpartx -a /dev/loop0 # dd if= of=/dev/mapper/loop0p1 # e2fsck -f /dev/mapper/loop0p1 # resize2fs /dev/mapper/loop0p1 # a lot of guides tell you to edit /etc/fst........
  • nf_conntrack: table full, dropping packet solution


    nf_conntrack: table full, dropping packet The above in some cases I've seen is a sign of a DOS attack or can occur if users are using services like torrenting, proxy, VPNetc... Do not take it lightly as the above can knock a server offline if the table becomes full and I've also seen full crashes and kernel panics shortly after. ........
  • Setting Ulimit


    I never found a solution to do it live (nothing worked that I found) so it looks like a relogin is required. Check your maximum file limit cat /proc/sys/fs/file-max 824460 This is different than your actual's user limit which you'll see below ulimit -n 1024 Try and set it higher but it won't work ulimit -n 65000........
  • Asterisk iptables block bruteforce attacks howto with fail2ban


    yum -y install fail2ban vi /etc/fail2ban/jail.conf [asterisk-tcp] enabled = true filter = asterisk action = iptables-multiport[name=asterisk-tcp, port="5060,5061", protocol=tcp] sendmail-whois[name=Asterisk, dest=you@example.com, sender=fail2ban@example.com] logpath = /var/log/asterisk/messages maxret........
  • CPanel Log File Locations for access_log,error_log, mysql


    All Errors (CPanel does not report by domain, but puts everything in a single log which Ithink is a bit silly and annoying): /usr/local/apache/logs/error_log Access_Logs They are found within the home directory of the site user eg.: /home/admin/access-logs/yoursite.com MySQL Logs /var/lib/mysql/yourhostname.err........
  • MySQL DELETE all but specific items or records howto


    DELETE FROM `wp_comments` WHERE NOT comment_author_email IN ('user@hotmail.com','another@hotmail.com') The above is an example of specific records you type out, but you could also base it on a subquery.........
  • Delete all comments from wordpress (in case of extreme SPAM)


    *Note this will delete all comments indiscriminately. DELETE FROM `wp_comments` To delete all but save specific comments based on "author e-mail use the following". Add more e-mails below in the same format if you have more. DELETE FROM `wp_comments` WHERE NOT comment_author_email IN ('user@hotmail.com','another@hotmail.com')........
  • wget test without actually downloading howto


    user the "--spider"switch and you can see what it would do. wget -r --spider dontryrealtechtalk.com........
  • Linux Howto Mount CD/DVD drive for sharing for other users


    sudo mount -o user /dev/sr0 cd You need the "user"option otherwise non-root or non-owners cannot view the CD and this would make it so no anonymous access to the CD/DVD mount would work. Note that most distributions including Ubuntu DONOT work unless you manually mount and share as shown above (Icouldn't find any other way in Ubuntu).........
  • Linux find what processes are swapping


    Here is a handy script that will check all processes and report what is swapping #!/bin/bash for pid in `ps x|awk '{print $1}'`; do result=`cat /proc/$pid/status|grep VmSwap|awk '{print $2}'|grep -v ^"0"` if [ ! -z "$result" ]; then programresult=`ps x|grep $pid|grep -v grep` if [ $? == 0 ]; then program=`echo $programresult|awk '{print $5}'|grep -v ^grep`........
  • Openvz OOM Centos Issue Memory Config Settings Solution


    Linux box13. 2.6.32-042stab076.5 #1 SMP Mon Mar 18 20:41:34 MSK 2013 x86_64 x86_64 x86_64 GNU/Linux even setting privvmpages to a specific setting DOES not affect "free -m" in containers. This is probably a kernel issue 23:36:29 up 159 days, 7:12, 4 users, load average: 0.42, 0.44, 0.33 [root@box13 ~]# free -m total&n........
  • PHP Security - Enable Safe Mode to increase security


    Everyone should be running with safe_mode on in /etc/php.ini (on Centos) as it makes exploiting your system more difficult is PHPcan't execute anything on the system if a script is exploited. For example with Safe_Mode on the only executable files on the system are ones in the safe_mode_exec_dir = /safephp This is crucial, if you must execute anything from PHPthen you have to copy the binary and assign to the user that Apache runs your site under.&........
  • [ERROR] Fatal error: Can't open and lock privilege tables: Incorrect key file for table 'user'; try to repair it - Solution


    service mysqld start MySQL Daemon failed to start. Starting mysqld: [FAILED] mysqld_safe cat /var/lib/mysql/server.err 130917 17:57:09 InnoDB: Started; log sequence number 0 0 13091........
  • LibreOffice Recovery Automatically Saved Documents


    Browse to this directory: ~/.config/libreoffice/3/user/backup/........
  • Unixbench Testing


    The first is a dual CPU AMD Opteron 2373EE (4 cores x 2) and I think it did bad because it has some old 250GB SATAs which can only do about 65MB/s max sequential reads. I think it should have blown away the second (AMD X4 640 Quad Core). [root@fs12home unixbench-4.1.0-wht-2]# ./Run make all make[1]: Entering directory `/root/unixbench-4.1.0-wht-2' Checking distribution of files ./pgms exists ./src exists........
  • Linux create htaccess file with username and password


    htpasswd -b -c filename username "password" -b = take the password that we specify in the command (don't prompt for it) -c = create the filename username=username password=password (I use quotes because it breaks if you use special characters)........
  • MySQL Allows blank user with no password to login


    I just realized I have some blank users which I deleted butI can still login to this dummy account without a password for some reason. mysql -u -p Welcome to the MySQL monitor. Commands end with ; or g. Your MySQL connection id is 5 Server version: 5.1.69 Source distribution Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved. Oracle is a registered trademark of Oracle Corporation an........
  • Dell Perc 6/i cannot downgrade


    I flashed an LSI Logic firmware to it and it broke the BIOS (cannot do Ctrl+R) for booting purposes but allows other functionality to work normally. I tried downgrading to a Dell firmware for Perc 6i but it won't work, not even with MegaCli wget http://downloads.dell.com/FOLDER00416606M/1/SAS-RAID_Firmware_W83M2_LN32_6.3.1-0003_A14.BIN --2013-08-26 12:53:39-- http://downloads.dell.com/FOLDER00416606M/1/SAS-RAID_Firmware_W83M2_LN32_6.3.1-0003_A14.BIN Resolvi........
  • CPanel How To Add A Domain Name Solution "Sorry, you must enter a domain. Please try again."


    Add a DNS Zone Results of adding zone Sorry, you must enter a domain. Please try again. Fill this out at the top (Imissed it) Domain Selection Ip Domain The issue was I didn't realize the form above had to be used,I thought it should work where you click on the user, domain and then click on the submit button and you'd go to the next step. But it doesn't, you need to........
  • yum update error


    yum update error Traceback (most recent call last): File "/usr/bin/yum", line 29, in ? yummain.user_main(sys.argv[1:], exit_code=True) File "/usr/share/yum-cli/yummain.py", line 229, in user_main errcode = main(args) File "/usr/share/yum-cli/yummain.py", line 145, in main (result, resultmsgs) = base.buildTransaction() &nbs........
  • screen Cannot open your terminal '/dev/pts/0' - please check. solution


    This happens when su'ing to a user and running screen screen Cannot open your terminal '/dev/pts/0' - please check. Solution (not secure for a shared server) chmod 777 -R /dev/pts ........
  • EXT4-fs error (device md20): ext4_add_entry: bad entry in directory #2552670:


    Jun 12 10:30:53 kernel: [724514.291670] EXT4-fs error (device md20): ext4_add_entry: bad entry in directory #2552670: rec_len % 4 != 0 - offset=216, inode=2553603, rec_len=94, name_len=84 Jun 12 10:30:53 kernel: [724514.292400] EXT4-fs error (device md20): ext4_add_entry: bad entry in directory #2552670: rec_len % 4 != 0 - offset=216, inode=2553603, rec_len=94, name_len=84 This happened when an unprivileged user was backing up a Windows filesystem, once they ha........
  • WD 20EARX Dead Again


    Another new drive bad from the start: Jun 2 15:14:18 one-desktop kernel: [15895.386779] ata2.00: exception Emask 0x50 SAct 0x1 SErr 0x280900 action 0x6 frozen Jun 2 15:14:18 one-desktop kernel: [15895.386782] ata2.00: irq_stat 0x08000000, interface fatal error Jun 2 15:14:18 one-desktop kernel: [15895.386784] ata2: SError: { UnrecovData HostInt 10B8B BadCRC } Jun 2 15:14:18 one-desktop kernel: [15895.386788] ata2.00: cmd 60/0........
  • WD 20EARX 2TB Bad within days


    This is just trying to read 5GB off the drive with dd and the drive initially tested ok but shortly after I wondered why I was seeing 2MB/s read speeds. Notice the "current_pending_sector", anytime I've seen it at anything above 0 even with no other bad fields/attributes, it means the drive is bad. ata1.00: exception Emask 0x0 SAct 0x3 SErr 0x0 action 0x0 ata1.00: irq_stat 0x40000008 ata1.00: failed command: READ FPDMA QUEUED ata1.00: cmd 60/00:00:........
  • init: tty (/dev/tty2) main process (1031) terminated with status 1 init: tty (/dev/tty2) main process ended, respawning


    After some fsck issues I can't boot my Centos 6.4, this just keeps repeating over and over. init: tty (/dev/tty2) main process (1031) terminated with status 1 init: tty (/dev/tty2) main process ended, respawning Disabling SELinux through Single User mode fixed this.........
  • MySQL my.cnf Server How To Secure/Bind to Localhost and Prevent Outside Connections Solutions


    [mysqld] datadir=/var/lib/mysql socket=/var/lib/mysql/mysql.sock user=mysql # Disabling symbolic-links is recommended to prevent assorted security risks symbolic-links=0 bind-address=127.0.0.1 The key is "bind-address", set that to 127.0.0.1 and no one from outside the server can connect.........
  • mysqldump: Couldn't execute 'show create table `general_log`': SHOW command denied to user 'user'@'localhost' for table 'general_log' (1142) - Solution


    mysqldump: Couldn't execute 'show create table `general_log`': SHOW command denied to user 'user'@'localhost' for table 'general_log' (1142) One of my clients almost found out the hard way, here is an unlikely situation that happened. 1.) Years ago the client had another VPS to which they backed up a BLOG nightly to an .sql file, what they forgot is that the file also contained all databases (they used the --all-databases option but forgot). So imagi........
  • mysql how to execute script from the bash prompt .sql


    mysql -u username --password='yourpassword' ........
  • Samsung Galaxy Note I717M Canadian Version, Root and Unlock


    I chose this because I heard a lot of stories about scams and that many providers I contacted said they can't unlock the Canadian I717s (one said "my Bell server" is down). This method worked perfectly on my Bell I717M and should work for all I717 in Canada, I was able to insert a foreign SIMcard. This will work abroad too but remember entering CWM mode is different for I717's in other countries (at least theUS). Step 1 - Root + CWM........
  • Bad Hard Drive Slows Down Computer


    Here's a proven example of what a bad hard drive can do, it was technically functioning OKin a RAID array but the system became extremely low and the load become high and IOWAIT was even higher and I always thought it was a bad application. The truth is that this failing 1TBHitachi has slowly gotten worse and caused huge slowdowns, (eg. 100% load on Thunderbird waiting for e-mails to load etc..). After swapping it out, tabs change instantly, emails are not lagged, and........
  • Hitachi Serial Numbers for Hard Drives without seeing the physical drive


    Here's what SMART tells me the serial number is: === START OF INFORMATION SECTION === Device Model: Hitachi HDS721010CLA332 Serial Number: JP2940HQ3ZY7KH Firmware Version: JP4OA3EA User Capacity: 1,000,204,886,016 bytes Device is: Not in smartctl database [for details use: -P showall] ATA Version is: 8 ATA Standard is:&nb........
  • Login and download all files script


    This is very handy if you're too busy and don't have time to download whatever files you need. The -D specifies the domains allowed, this is because I specified -H which means foreign hosts are allowed, if you don't restrict them you'll end up going to the whole internet via ads and other links just like a search Engine would follow. -l 0 specifies to go deep, to as many levels as possible/as exist. -e robots=off is important because robots.txt often says you can't vie........
  • Howto Copy/Backup/Restore All Firefox Settings/Preferences/Addons/Bookmarks to another computer/desktop


    I've used rsync again for this because I found it very simple, I've only excluded the Cache directory since it's not necessary and could be several GB in size. rsync -Phaz --exclude=Cache/* user@remotehost.com:/home/user/.mozilla/firefox/profile.default/* /home/user/.mozilla/firefox/ec1n9opl.default/ This is a great way once again to get going how you were on the old/remote computer fairly quickly. It even restores all of your history in........
  • Thunderbird How-To Copy/Backup/Restore Accounts and Settings to Another Computer


    The best way is to use rsync, I've set it up so it doesn't copy unnecessary files, or at least ones I'm sure aren't needed. Here is the rsync command Iused (adapt to your specific Thunderbird profile location): rsync -hazv user@remotehost.com:/home/user/.thunderbird/sbrer.default/* /home/user/.thunderbird/4nyb0.default/ --exclude=global* --exclude=Cache --exclude=ImapMail --exclude=Mail This is a great way to get your e-mail accounts going on a new c........
  • CPanel error: "Your SSL certificate failed to install on your site."


    This error in my experience is user error although CPanel doesn't help, this message doesn't give you much to go on. Let's talk more about the process of setting up SSL with CPanel. Your site must have a dedicated/non-shared IP to even have the option of creating an SSL Certificate. You must create a Private Key (do not delete this private key!) You must create a CSR (Certificate Signing Request) Use CSR to create cert........
  • Centos how to upgrade from PHP 5.2 to 5.3 without downtime


    This may sound silly but there will be conflicts/issues with the default Centos repository so you have to use a third party like remi (I prefer not to do this but it's the only option unless you migrate your sites/data to another server or can stand some downtime-not an option IMHOon a production server). You may need to upgrade to PHP5.3 to run Joomla or many other reasons. Your host needs to use PHP 5.2.4 or higher to run this version of Jo........
  • ntpd[7047]: can't open /var/lib/ntp/drift.TEMP: Permission denied solution


    ntpd[7047]: can't open /var/lib/ntp/drift.TEMP: Permission denied chown ntp.ntp /var/lib/ntp/ The solution is shown above and changes the ownership to ntp.ntp which is what the ntpd daemon/server is running as. This is based on Centos but the same idea will apply on any other OS. You can do a "ps aux|grep ntpd" to see what it is running as in the case it's running as a different user. After that this annoying message wil........
  • Joomla Error - JFolder::create: Could not create directory


    JFolder::create: Could not create directory Plugin Install: Failed to create directory: This can occur when trying to upload content or when installing themes/templates. It's usually not a permissions issue per say but doing a 777 (which is very insecure) will fix it. But the real problem solution is that the owner of the files is different than the owner of the Apache process/server. Eg. if your Apache is running as user "apache........
  • MySQL Authentication fails after Upgrade to Version 5.5


    ERROR 1045 (28000): Access denied for user 'contentmanager'@'localhost' (using password: YES) For fun I thought I'd reset the password: GRANT ALL ON thecontent.* TO contentmanager IDENTIFIED by 'dfdfsdfdsfsdfsd'; ERROR 1470 (HY000): String 'contentmanager' is too long for user name (should be no longer than 16) This is ridiculous that this new version has some bizarre 16 character username limit and not only that but i........
  • setquota: Mountpoint (or device) / not found. setquota: Not all specified mountpoints are using quota. with openvz solution


    Directadmin Error when changing user settings/saving Details Error with system Quotas setquota: Mountpoint (or device) / not found. setquota: Not all specified mountpoints are using quota. Debug Guide You have to disable and enable the quota's using vzquota on and off. After that it will work.........
  • Windows Secret Hidden Temp Directory to free out of disk space issues


    Replace "Administrator" with your username. C:Documents and SettingsAdministratorLocal SettingsTemp Ihave often found several gigabytes of temporary files in there! Just be warned that they may not all be deletable if the files are being used by open programs (so close everything you can). This helped me in a pinch many times when for apparently no reason gigs of disk space are being used for an unknown reason.........
  • Asterisk - Peer is not supposed to register


    NOTICE[5628] chan_sip.c: Registration from 'user ' failed for '192.168.5.25' - Peer is not supposed to register You have to setup as a "friend" and not "peer". Set: type=friend........
  • SSH error slow login debug1: An invalid name was supplied Cannot determine realm for numeric host address - Solution


    debug1: An invalid name was supplied Cannot determine realm for numeric host address debug1: Local version string SSH-2.0-OpenSSH_4.3p2 Debian-9etch3 debug1: An invalid name was supplied Cannot determine realm for numeric host address debug1: An invalid name was supplied A parameter was malformed Validation error Solution, disable auth from the ssh client (this is a client side error)........
  • LOG: MAIN PANIC failed to expand condition "${if eq {$authenticated_id}{}{0}{${if eq {$sender_address}{$local_part@$domain}{0}{${if match{$received_protocol}{N^e?smtps?a$N}{${perl{checkbx_autowhitelist}{$authenticated_id}}}{${if eq{$received_prot


    I experienced this with CPanel's Exim after an auto-update (a Google of this error produces lots of complaints with few clear solutions). In this case I'll put the solution at the top. Run /scripts/buildeximconf to rebuild the Exim config and it should be fine after that. mail -vs "from test" user@dest.com < .bash_history LOG: MAIN cwd=/root 4 args: send-mail -i -v user@dest.com LOG: MAIN &........
  • The Importance of a High Quality Power Supply/Power Supplies To Prevent Overheating/System Crash/Hardware Damage


    For years I've always built cheap systems believing that there is little difference in more expensive components when it comes to reliability and quality, I generally believe this still except for Power Supplies. I've always bought cheap cases with nice sounding 350-550W stock/cheap/crap power supplies and haven't had any issues for the most part until recently. One such case is an NGEAR case with a 550W Optimax power supply, I always read that these supplies don't produce the........
  • Asus VE247H 23.7" Inch LCD/LED Backlit Monitor Dead/Stuck Pixel Policy Complaint


    I've thought for awhile that Asus has been banking on its years old reputation for quality amongst gamers and enthusiasts and I think I'm right. My Asus VE247H Monitor with a supposed 2MS refresh rate has 1 red/stuck/dead pixel but fortunately it can only be seen on a non-true black picture or against a blue screen. I have several Asus products and find they're all of fairly poor quality. First of all their motherboards have given me the most issues of any brand, they te........
  • Linux Ubuntu Nvidia GT430 Lockups/Errors/Freezes NVRM: os_schedule: Attempted to yield the CPU while in atomic or interrupt context


    I'm running Ubuntu 10.10 with Asus NVIDIA GT430 2.6.35-32-generic-pae #65-Ubuntu SMP Tue Jan 24 14:06:16 UTC 2012 i686 GNU/Linux Nvidia binary driver: 260.19.06 The screen sometimes completely freezes and locks up or everything starts going very slow: [1903398.100007] NVRM: os_schedule: Attempted to yield the CPU while in atomic or interrupt context [1903402.373210] NVRM: Xid (0001:00): 53, CMDre 00000000 00000080 00000000 00000005 00........
  • What's Needed To Fix Linux


    I really am a Linux fan but my comments here may not show it. Although I'm quite familiar with Linux CLI to administer servers, I find Linux GUI OS's like Ubuntu at times very clunky. This is partially because there's no such thing as a "self-made" Linux from scratch where the UIwas designed by a single team. Linux is made up of several different projects that are generally completely separate and this lack of integratiion is a key issue that makes things f........
  • iptables block torrents/torrenting


    This is a very basic method and won't work in all cases but will reduce the chance of torrenting/abuse by your server users. iptables -A INPUT -p tcp --destination-port 6881:6999 -j REJECT iptables -A OUTPUT -p tcp --source-port 6881:6999 -j REJECT........
  • Drupal/MySQL database error: PDOException: SQLSTATE[42000] [1044] Access denied for user 'db_user'@'localhost' to database 'dbname' in lock_may_be_available() (line 167 of /home/user/public_html/includes/lock.inc).


    PDOException: SQLSTATE[42000] [1044] Access denied for user 'db_user'@'localhost' to database 'dbname' in lock_may_be_available() (line 167 of /home/user/public_html/includes/lock.inc). The username and password were correct but some reason CPanel added the user with no permissions! Edit the user's permissions to include "All" from Cpanel or MySQL and that is the solution.........
  • samba/smbd connection to share problems and solutions


    I'll start by showing some problems in the logs: [2011/08/07 16:22:06, 0] param/loadparm.c:8569(process_usershare_file) process_usershare_file: stat of /var/lib/samba/usershares/movie failed. Permission denied [2011/08/07 16:22:06, 1] smbd/service.c:676(make_connection_snum) create_connection_server_info failed: NT_STATUS_ACCESS_DENIED That means you don't have permission to access the fi........
  • screen Cannot open your terminal '/dev/pts/2' - please check.


    The solution to this screen issue is simple. This happened to me in Centos 5 as a user, but I also su'd to it and I don't have any password for it. I've read some people say this is more common when su'ing. The solution is simple though, just give others rw access to the corresponding pts whether it's 0,1,2 etc..: As root do chmod o+rw /dev/pts/2 ........
  • IO/delay and high load when a SATA hard drive dies


    dd if=/dev/sda of=/dev/null creates ever increasing load every second. After minutes the load has moved up to 4.79 I've tried with two different discs in my system. I wonder if it's a delay or problem with the SATA bus because one drive I have connected has recently failed. I notice when drives fail that you get some IO/blocking issue when they don't respond properly. Yes I believe it was, because here's the same disc after removing the dead........
  • Openvz Container IP not working suddenly Solution


    This may not apply to everyone but here is what happened to me. One day my IP connectivity for one container went dead, I could ping the hostnode from it and the hostnode could ping it but there was no external routing. I restarted the network service but it didn't help. I checked the routing table inside the VPS and the host and everything looked normal. Iadded another different IPon the same subnet to the container and it worked. Right away I st........
  • Linux Out of Memory OOM Object Killer Solution "Out of memory: kill process 1955 (sshd) score 81 or a child"


    I had a system running a 128MB live CD image with 2.8 gigs of available RAM and the OOM kernel killer went crazy when using dd for more than 8 minutes and kept killing everything. I've read that this is due to a low-memory issue and paging in the kernel and 32-bit systems with lots of RAM. I even enabled swapspace on my LiveCD and the issue happened 25 minutes into dd rather than 8 minutes, so what gives? Also no swap space was ever used! cat /proc/s........
  • How To Test If Your Hard Drive Is Good/Signs of dying hard drive


    I like dd, although it only reads it, usually a read test of the entire disk will uncover if your hard drive is bad in some parts. This is a good thing to do at least once a month, a lot of times bizarre program behavior, laginess and crashing/unnmounting problems etc.. are due to a failing disc and SMART won't know it or indicate a problem: We must also remember there's never a guarantee, I've found that ever since we moved to larger and more platters per drive with 1TB drives........
  • smart is not smart, it thinks a dead drive is still good


    I had a dying drive that smart thought until it totally disappeared was a good drive, and actually all parameters did look fine but this system was causing my system to lockup and other bad behavior: === START OF INFORMATION SECTION === Device Model: WDC WD20EARS-00MVWB0 Serial Number: WD-WMAZ20139 Firmware Version: 50.0AB50 User Capacity: 2,000,398,934,016 bytes Device........
  • Hitachi 2TB HDS5C3020ALA632 drive DOA


    I had one of these shipped and it was not recognized when plugged in, here's what a dead drive looks like (I assume it's teh circuit board which is dead): ata1: link is slow to respond, please be patient (ready=0) ata1: softreset failed (device not ready) ata1: SATA link up 3.0 Gbps (SStatus 123 SControl 300) ata1: link online but device misclassified, retrying ata1: link is slow to respond, please be patient (ready=0) ata1: softreset f........
  • How to recover from dead DRBD partition/hard drive in two simple commands


    This assumes that you've at least created the correct partition for your DRBD already. Notice that I am "diskless", that's because either your DRBD partition doesn't exist/has been renamed (eg. sdb becomes sda when sdb dies and you reboot) or because that drive is really actually dead/gone. *If you need to permanently change the partition/device for your resource be sure to edit /etc/drbd.conf on both hosts and reload the config. (replace r0 with........
  • Kernel/make compilation time and how to improve compile times/compile the Linux kernel faster without hardware upgrades


    I thought only a faster CPUand SSDwould help but I already have a Quad-Core CPU and it wasn't being maxed out. The actual tests were performed on an AMD-V enabled 128MB dual core VMWare container though. There is a flag that can be passed to make in order to start multiple threads, by specifying 4 threads I was able to reduce the whole kernel compilation time from scratch by about 50%! (65minutes vs 31minutes!). *Yes I did do a make clean before each co........
  • mysql enable slow query logging/Query Cache Solution - find/track cause of slow mysqld/high IO/CPU usage


    If you have a webserver and find you have high IO/lagginess MySQL is one of the first things to check. It turns out MySQL was my problem and it was creating a high load on my server, especially for IO. How to Enable MySQL Slow Query Logging To Find Slow Performance/Queries vi /etc/my.cnf Add this anywhere under [mysqld] #slow queries log-slow-queries = /var/log/mysql/mysqlslowqueries.log long_query_time = 1........
  • iPhone 3G/3GS/4 Undelete Photos/Videos Datarecovery


    I found this technique listed in many places which shows you how to use a common Linux tool "dd" to dump the raw partition of your iPhone. I give credit to this site for showing me the correct way to dd from the iPhone, I never thought to try it in the other direction:http://log.ijulien.com/post/182804914/iphone-3gs-data-recovery Requirements 1.) Jailbreak your........
  • Yahoo Mail (email) DNS Server Out Of Date Problems


    I don't expect this to be solved soon but some of Yahoo's DNS servers are out of whack. I changed the IPs of some nameservers of some domains and now most Yahoo users can't e-mail to those domains! As you can see below by the "No MX or A records for mychangedomain.com", now Yahoo's DNS/mailserver DNS cache is wrong. You would think they would at least have cached the old incorrect records, but instead for some reason their DNS cache has no entry and doesn't seem........
  • Enable SPAMASSASSIN on Postfix in 5 minutes


    Centos 5 Postfix and SPAMASSASSIN Tutorial yum install spamassassin chkconfig spamassassin on vi /etc/mail/spamassassin/local.cf ############## #required_hits 5 #report_safe 0 #rewrite_header Subject [SPAM] #5 is the least restrictive (means only the most obvious SPAM is caught. 0 is obviously the most restrictive/sensitive and would have lots of false positives require........
  • ls: error while loading shared libraries: libtermcap.so.2: cannot open shared object file: No such file or directory solution


    ls ls: error while loading shared libraries: libtermcap.so.2: cannot open shared object file: No such file or directory This is not an ldd problem or case of anything missing, this only happened after I upradedUbuntu. declare -x PATH="/home/user/bin:/usr/local/bin:/usr/bin:/bin:/usr/games" "/home/user/bin" is the problem! It's weird because I have no idea how it happened.........
  • Plesk Get List of E-mail Users & Aliases


    When migrating away from Plesk I couldn't figure out an easy way to get a straight list of all e-mails, but here is where I found the solution: http://nakuls77.wordpress.com/2008/08/30/details-of-email-ftp-database-users-from-psa-database/ mysql> SELECT mail.mail_name, accounts.password, domains.name FROM mail, accounts, domains WHERE domains.id=mail.dom_id AND mail.account_id=accounts.id; mysql> SELECT CONCAT(mail.mail_name,’@’,domains.name) AS Em........
  • OpenOffice Calc SUM function not working Solution - Result is always 0/apostrophe appears in front of all numbers.


    I right clicked all applicable cells and chose "number" but that's enough. I notice when I click the cell there is an invisible ' in front of the number: '33.64 Calc imported my CSV and decided to add a ' in front of the numeric currency values!!!*Actually the problem occurs when you right click the cells and change the type from text to number, no matter what format you choose. If I change it to be currency i........
  • sshfs cannot unmount error: device is busy. (In some cases useful info about processes that use the device is found by lsof(8) or fuser(1))


    umount: /home/diret/mount: device is busy. (In some cases useful info about processes that use the device is found by lsof(8) or fuser(1)) I tried everything (fusermount -u) to unmount it but the only thing that worked was actually doing this: ps aux|grep sshfs Then I identified the sshfs connection and did: kill -kill pid........
  • Postfix/Any Email Server check for Open Relay


    The first thing you need to remember is not to check from the same host/server itself. This is a silly mistake I made, the reason is that many mailservers and especially postfix are configured to allow relaying from the localhost/same host. If you do that you'll get a false positive. *Make sure you test from another host/system than the mail server itself! telnet yourmailserverhost.com 25 220 Courier (FreeBS........
  • sshd[9217]: Authentication refused: bad ownership or modes for file /root/.ssh/authorized_keys


    sshd[9217]: Authentication refused: bad ownership or modes for file /root/.ssh/authorized_keys I made sure the entire .ssh subdir is owned by the user root (this is root's account); chown -R root.root .ssh chmod 600 .ssh/authorized_keys but it still doesn't work and gives me the same message sshd[7339]: Authentication refused: bad ownership or modes for directory /root chmod 700 /root........
  • MySQL Out of Range Solution for DATETIME field


    Affected rows: 0 Warning: #1264 Out of range value adjusted for column 'deleteon' at row 1 SQL query: UPDATE `custtable`.`custinfo` SET `deleteon` = '2011-02-29 00:00:00' WHERE `custinfo`.`custid` =105 LIMIT 1 ; This happened after a migration to a new SQL database due to user error. The old database server MySQL 3.23 or 4 allowed an impossible date to be entered by a user. As we know February 29th DOESNOT exist but the database al........
  • Understanding /etc/aliases from sendmail when using with postfix or other MTA's


    understanding /etc/aliases *remember to apply changes you need to run "newaliases" after editing /etc/aliases one thing I don't get is that it doesn't allow you to specify the whole e-mail address on the left-hand side eg: yourfullemail@domain.com: someotheremail@domain.com postalias: warning: /etc/aliases, line 109: name must be local (if you try the above) It works more like this: your........
  • Ubuntu 9.04 Crash


    CPU/Kernel/MB/RAID problem? Jan 5 12:45:05 testbox kernel: [653298.890004] BUG: soft lockup - CPU#0 stuck for 61s! [hal-acl-tool:4168] Jan 5 12:45:05 testbox kernel: [653298.890005] Modules linked in: vmnet vmci vmmon binfmt_misc drbd video output input_polldev ocfs2_stackglue ocfs2_dlmfs ocfs2_dlm ocfs2_nodemanager configfs k8temp hwmon_vid lp snd_hda_intel snd_pcm_oss snd_mixer_oss snd_pcm snd_seq_dummy snd_seq_oss snd_seq_midi snd_rawmidi........
  • Installing Webmin & Enabling SSL


    Webmin Setup Centos 5: wget http://downloads.sourceforge.net/project/webadmin/webmin/1.530/webmin-1.530-1.noarch.rpm?r=http%3A%2F%2Fwww.webmin.com%2Fstandard.html&ts=1294339690&use_mirror=surfnet [1] 24229 [2] 24230 [root@host ~]# --2011-01-06 21:48:20-- http://downloads.sourceforge.net/project/webadmin/webmin/1.530/webmin-1.530-1.noarch.rpm?r=http%3A%2F%2Fwww.webmin.com%2Fstandard.html Resolving downloads.sourceforge.net... 216.34.181.........
  • Virtualmin/Webmin Postfix Error: The status of your system is being checked to ensure that all enabled features are available, that the mail server is properly configured, and that quotas are active ..


    Virtualmin Postfix Error: The status of your system is being checked to ensure that all enabled features are available, that the mail server is properly configured, and that quotas are active .. A problem was found with your Postfix virtual maps : No map sources were found in the Postfix configuration .. your system is not ready for use by Virtualmin. ........
  • crontab/cronjob running multiple times at the wrong time


    crontab not working It is running as user Apache I've tried 0 0 * * * (which means midnight 00:00) and it does run at midnight but also 13:25 for some reason? 25 0 * * * with this it runs at 00:25 but again also at 13:25 Solution - Restart the Cron Service (especially if you changed your time/timezone) *Update I had a suspicion that changing the timezone a few weeks ago caused this. I restarted lhe cron service and the problem h........
  • SSH delay problem UseDNS and disabling GSSAPI does not help


    The normal solution doesn't help or apply here: ssh -v user@192.168.5.41 OpenSSH_4.3p2 Debian-9etch3, OpenSSL 0.9.8c 05 Sep 2006 debug1: Reading configuration data /etc/ssh/ssh_config debug1: Applying options for * debug1: Connecting to 192.168.5.41 [192.168.5.41] port 22. debug1: Connection established. debug1: permanently_set_uid: 0/0 debug1: identity file /root/.ssh/identity type -1 debug1: i........
  • Cygwin and crontab backups via ssh/scp/rsync


    Install the "Editors" and "Net" groups that will give you rsync, ssh, ssh-keygen and cron. The trickiest thing that I keep forgetting about each time is you have to run "cron-config" which adds the cron service to Windows, and without doing that obviously no cron jobs will be run thus making automatic backups impossible. Warning about rsync/cygwin and using the -a archive switch. It's a good thing I caught this because it doesn't work ri........
  • rsync preserve attributes, permissions/ownership and times without being root non-root user


    One of the purposes of rsync is to backup whole filesystems and archive them but how can you do that properly and restore things to normal if all permissions and ownerships are not preserved from your root filesystem? It's not desirable to have everything running as root, especially not just for an rsync. The Easy rsync preserve permission solution for non-root users sudo is the answer and all you have to do is edit /etc/sudoers At the end o........
  • Ubuntu/Debian DRBD 8.0 Setup Guide


    I've only used it on Centos, soI thought I'd make a quick Debian guide: Install the DRBD Package apt-get install drbd8-utils Reading package lists... Done Building dependency tree Reading state information... Done The following packages were automatically installed and are no longer required: libswfdec-0.8-0 Use 'apt-get autoremove' to remove them. The following........
  • yum in Centos 5/Xen halts and exits suddenly


    yum exits in the middle The problem is this VPS seems to be an OpenVZ template from HyperVM. The only way to make it work was to disable i386 packages since this was an x64 kernel. That shouldn't be necessary but it was the only way to make yum stop quitting after the first package or two. I couldn't find any issue by checking the logs either. echo y|yum install vim-minimal telnet expect jwhois net-tools slocate iptables elinks gawk L........
  • mdadm RAID 1 adventures


    I separated the 2 drives in the RAID 1 array. 1 is the old one /dev/sda and is out of date, while the separated other one /dev/sdc was in another drive and mounted and used with more data (updated). I wonder how mdadm will handle this: usb-storage: device scan complete md: md127 stopped. md: bind md: md127: raid array is not clean -- starting background reconstruction raid1: raid set md127 active with 1 out of 2 m........
  • WD (Western Digital) Advanced Format Drive Lagged/Slow Speed/Performance/Design Flaw EAD/EARS problem WDC WD20EARS-00S8B1


    Let the numbers speak for themselves, from what I read the Load_Cycle_Count which is very high (more than 500,000/half a million times) is the number of head parks. What a stupid"Green" design and design flaw which will probably mean an early life for the drive. This is almost as silly as Seagate's new reputation for BSY/poor quality disks since the 7200.11 series. To make it worse this is also when Western Digital introduced "Advanced Format" o........
  • VirtualBox some USB passthrough devices greyed/grayed out unavailable solution


    The solution is simple but it's a wonder why VBOX doesn't address it directly? Perhaps newer versions will but you have to add your user to the "vboxusers" group and then login and logout and you'll see the devices you wanted but couldn't access are now available. The weird thing is that the grayed out issue doesn't happen with all devcies but one notable thing is the Apple iPhone especially in DFU or Recovery Mode which is an big issue for some people.........
  • How not to change an IP address in CPanel during a migration


    /usr/local/cpanel/bin/swapip domain(s) It simply doesn't work, the Apache VHOSTS remain 100% unchanged, why does this script exist? I'm sure it would work from the control panel but I am locked out because my IP was changed and it doesn't match the CPanel license. I wish CPanel would make it easier to update the license IP. I even took it a step farther, I manually edited the vhosts and restarted Apache and it........
  • VirtualBox Error Failed to start the virtual machine Centos 5.5 Mirror. Medium '/home/testuser/.VirtualBox/HardDisks/Centos 5.5 Mirror.vdi' is not accessible. UUID {a1a9fad7-0402-4867-b8f3-39fb49454bc5} of the medium '/home/testuser/.VirtualBox/HardD


    Virtualbox Error I tried to copy a .vdi of one container to use in another one, basically to clone instead of having to install the OS again. Failed to start the virtual machine Centos 5.5 Mirror. Medium '/home/testuser/.VirtualBox/HardDisks/Centos 5.5 Mirror.vdi' is not accessible. UUID {a1a9fad7-0402-4867-b8f3-39fb49454bc5} of the medium '/home/testuser/.VirtualBox/HardDisks/Centos 5.5 Mirror.vdi' does not match the value {4945a0e8-0ed5-4736-9088-bcaf........
  • Installing Virtualbox on Centos 5.5


    wget http://download.virtualbox.org/virtualbox/3.2.8/VirtualBox-3.2-3.2.8_64453_rhel5-1.i386.rpm rpm -i http://download.virtualbox.org/virtualbox/3.2.8/VirtualBox-3.2-3.2.8_64453_rhel5-1.i386.rpm error: Failed dependencies: libGLU.so.1 is needed by VirtualBox-3.2-3.2.8_64453_rhel5-1.i386 libSDL-1.2.so.0 is needed by VirtualBox-3.2-3.2.8_64453_rhel5-1.i386 libXmu.so.6 is needed b........
  • jailkit for chroot ssh account security tutorial and fix for error


    This was done on Centos butI think it's easier on Debian machines, the paths that it is set to use are tailored towards Debian, so there is some fiddling that needs to be done on Centos. This is for chrooting ssh, but jailkit has other uses than just SSH jails but I won't cover them in this writeup. 1. Install jailkit yum install jailkit 2. Setup Jail Home mkdir /home/jail chown root:root /home/ja........
  • Realtek r8169 1gbit/1000mbit NIC/Ethernet Goes Down/Halts on Large File Transfer/Heavy Network Usage


    This is obviously a bug in the r8169 kernel module and it seems to affect a lot of people. I upgraded to the latest kernel and hope this won't happen anymore, as it is a very serious error. This is especially serious for those who are running servers with this chipset, who can afford for the NIC to randomly go off-line for no apparent reason? [655548.189113] type=1505 audit(1277067560.902:5): operation="profile_load" name="/usr/bin/freshclam&q........
  • FUSE/Curlftpfs mount ftp account as drive partition in Linux


    This is a great way to use your ftp server space, for example on your web hosting account (althoughI believe many hosts don't allow storage like this), but if you have a VPS/Dedicated Server etc.., this would be perfect. Imagine how easy it is to work with an ftp account that you can just mount as a normal partition or directory in Linux, it would be great for backups etc.. Name curlftpfs - mount a ftp host as a local directory Synopsis........
  • cPanel complaint - No Shared SSL! cPanel 11.25.0-R46156 - WHM 11.25.0 - X 3.9


    I've recently used CPanel on the admin side for the first time and have to say I hate it. Everything from the layout to the functionality screams "hackish". It just lacks so many common sense features and way of working. I was never 100% impressed with Plesk but the basics were definitely laid out and done in a sensible manner, even though it is made by a Russian company, they definitely thought about how to make a Control Panel. I have no idea why people........
  • MySQL Recover/Reset Lost/Forgotten root Password


    One note is to secure MySQL, I don't know for sure but I believe you could login to MySQL remotely with no password during this operation (I'm not sure, maybe it doesn't accept blank passwords but I firewall MySQL port anyway and recommend you do the same). First edit /etc/my.cf Under the [mysqld] field add the following line somewhere: skip-grant-tables Now restart mysql: service mysql restart or on Debian sty........
  • Debian 5.04 RAID 1 mdadm boot problem GRUB error


    I successfully created a single RAID 1 partition which includes /boot inside it and my root directory through the Debian installer. It said GRUB installed successfully but when I try booting the OS it seems GRUB can't read anything. When trying to boot from GRUB GRUB Loading stage 1.5. GRUB loading, please wait... Error 2 I get "Error 2" when trying to boot Debian. I also notice from a LiveCD that........
  • Centos 5.5 RAID 1 boot issue


    I installed 5.5 with a 300GB RAID 1 partition (boot is also on this partition). It booted up fine the first few times until after I used a Live CD and accessed the array, and it became named /dev/md127 for some reason. Now whenI boot into CentOS I get a kernel panic and different errors, once I got "invalid superblock", even though the array is fine (it didn't happen again, probably because I was sure to dismount and stop the mdadm array properly). Here's what........
  • Unixbench Score on Core i5 750 with OpenVZ Kernel vs Xen/Openvz


    This was unbelievable how much the Xen kernel slows things down, keep in mind both tests were done on the hostnode, one was with the Openvz-Xen hybrid kernel and the other was just OpenVZ. You can see the performance difference is nearly 300% better when not using the Xen kernel. OpenVZ-Xen Kernel Test Results (I was wondering what was wrong/so slow with my Core i5!) # # # # # #&n........
  • WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED!


    The easiest way is if you have a secure way to connect and verify the hostkey of the remote host by using this guide. @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ @ WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED! @ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ IT IS POSSIBLE THAT SOMEONE IS DOING SOME........
  • OpenVZ user_beancounters kmemsize failcnt Processes Timing Out/Doing Nothing/Zombie


    cat /proc/user_beancounters produces the following: kmemsize 1861537 5139870 12752512 12752512 26965041 Notice the failcnt "26965041", that is for kmemsize and at first it confused me. The system had enough guaranteed and enough burst RAM available. kmemsize is a variable indepedent of that, but who cars about the explanation right, let's just make thing........
  • Starting online migration of CT 300 to 192.168.5.45 Error: vzcpt module is not loaded on the source node Error: Can't continue online migration Error: vzcpt module is not loaded on the source node Error: Can't continue online migration


    Starting online migration of CT 300 to 192.168.5.45 Error: vzcpt module is not loaded on the source node Error: Can't continue online migration Error: vzcpt module is not loaded on the source node Error: Can't continue online migration This is a very easy fix, you just load the appropriate modules on the source and target node (althoughI don't know why the vzmigrate tool can't do that for the user on both ends):........
  • SSH Automatic/Passwordless Logon - Setup Public Key Encryption In Single Command


    This is a very simple solution, but most guides out there make you login twice (once to scp the key) and once to put the key in authorized_keys. There's no need for that. If you don't already have a ~/.ssh/id_rsa.pub just type "ssh-keygen -t rsa" and keep hitting enter until it's done :) Just use this code to easily enable passwordless login with SSHD key=`cat ~/.ssh/id_rsa.pub`;ssh user@192.168.5.25 "echo $key >> ~/.ssh/auth........
  • Seagate Drive 500GB Drive Dying


    This drive is clearly on the way out, the Kernel knows it but I'm surprised that SMART is not concerned. I didn't blame Seagate for their past issues until now. This hard drive has hardly been used and has not even been powered on for a year according to SMART. Home page is http://smartmontools.sourceforge.net/ === START OF INFORMATION SECTION === Model Family: Seagate Barracuda 7200.11 Device........
  • MySQL TEXT field size length limit reminder, don't truncate your data!


    I thought there would be an error message or warning from MySQL in the case that the text you submit is greater than the allowed limit based on the field. So essentially I submitted text that was about 120,000 characters long, whereas the limit of TEXT is just 65,535 characters! I almost lost half of my data/what I typed without knowing it! I just altered the field type in my database from TEXT to LONGTEXT. I can't see how LONGTEXT wouldn't be long enough for MOST........
  • Seagate 7200.11 firmware defect in 500GB, 1000GB (1TB) and 1500GB (1.5TB) Hard Drives


    Seagate Inventory/Firmware Check I heard about this issue a long time ago but never looked into it. I figured I wasn't affected since my 500GB drives were running for so long. I've been using Seagate's since 2002 and to this day all of the drives I have are alive from Seagate. *Update the bad news is that I realize one of my 500GB's is about to die, it's not even a year old, but is also not affected by the recall according to Seagate! Seagate Inventory/Firm........
  • Convert HDD/Hard Drive Partition(s) into non-RAID into RAID 1 using existing data without data loss and without reformatting.


    Before we start I take no responsibility for this, you should have a backup and if you make a mistake during this process you could wipe out all of your data. So backup somewhere else before starting this as a precaution, or make sure it's data you could afford to lose. The RAID 1 Setup (Hardware Wise) I've already setup my 2 x 1TB (Seagate) drives with identical partitions, make sure your new hard drive (the empty one) is setup like your curr........
  • Monitor MB/s Disk IO Usage/Bandwidth - Use iostat from the sysstat Package


    The binary "iostat" comes from the package "sysstat" and is available on all Linux/Unix like platforms. Use the "-m" option to give you what you probably want, which is to see in MB/s how much bandwidth each disk is doing. iostat -m Linux 2.6.24.2 ((none)) 04/16/10 avg-cpu: %user %nice %system %iowait %steal %idle ........
  • Linux EXT3 16GB-17GB maximum filesize issue solved/how to fix


    I have no idea why but mkfs.ext3 defaults to a patheticlly small blocksize of 1024 bytes/1KB (kilobyte). That means the maximum filesize is ONLY 16GB! With 2KB/2048 bytes you get a 256 GB maximum filesize, and with 4KB/4096 bytes you get 2TB! I finally noticed/paid attention to this after realizing that with rsync and scp that no file larger than 17GB could be transferred. I then realized it must be a file size limit on the partition. Here is what tune2fs tol........
  • tar gzip: stdout: File too large - Error Size Limit on Large file > 17GB


    The folder I was trying to archive is about 72GB, but much like rsync at about 17GB it chokes because of the filesize. What's with so many common and essential Linux tools having such limitations? I guess it is likely that the authors never wrote their code with the idea that files would be so large but it's still very annoying. It's important to stay on top of these limitations on production servers because I didn't realize what happened until I checked the file with "........
  • Picking an FTPD (vsftpd) Server in Linux Centos/Debian


    I decided on using yum to help me decide even though I normaly use proftpd I decided to see what else I could find. yum search ftp Loaded plugins: fastestmirror Loading mirror speeds from cached hostfile * rpmforge: ftp-stud.fht-esslingen.de * base: mirrors.netdna.com * updates: updates.interworx.info * addons: yum.singlehop.com * extras: mirrors.netdna.com rpmforge........
  • Codelite C++ IDE is a Cross Platform Unix/Linux (Mac OS, Ubuntu etc..) and Windows for C++ development


    Codelite is a great choice and I intend on getting back into C++ development and I think Codelite is great being cross platform. It looks like it was designed with a lot of thought and should do the job better. I really dislike the bloated and confusing IDE's from big companies like Microsoft where you usually have to use .NET and other useless technologies that just give Microsoft the advantage over you, the programmer, and the users.........
  • Windows XP How To Edit/Find Recent Documents and "File -> New" Templates to create New Word Document, Text/Notepad, Excel etc...


    All you have to do is browse to: C:Documents & SettingsYourUserName and you'll see the following: Inside "My Recent Documents" are of course shortcuts to the most recent documents you opened Inside "SendTo" is your sendto, you could edit that to Send a file to a network destination, your Flash Drive........
  • Compaq V2405CA Laptop - Unixbench Performance Test


    Here are the results, it is Sempron 3000+ AMD Mobile, 500Gig HDD, 512MB RAM with shared ATI Radeon graphics. # # # # # # # ##### ###### # # #### # # # # ## # # # #&nb........
  • PHP cannot access /usr/bin/openssl


    PHP cannot access /usr/bin/opensslI have verified the username that runs the process is able to access /usr/bin/openssl and it does exist but the PHP script is saying it doesn't exist: [code:1:1fd0f3abbe] if (!file_exists($OPENSSL)) { //echo "ERROR: OPENSSL $OPENSSL not foundn"; }[/code:1:1fd0f3abbe] I don't get itI can clearly see the contents of /usr/bin by using the PHP system fu........
  • SSH automatic login without password


    SSH automatic login without passwordlocal> ssh-keygen -t rsa -f .ssh/id_rsa -t is the encryption type -f tells where to store the public/private key pairs. In this case, the .ssh directory on home is being used A password will be asked; leave this part blank, just pressing Now, go the .ssh directory, and you will find two new files: id_dsa and id_dsa.pub. The last one is the public part. Now, copy the public key to the serv........
  • CREATE Database/Granting Privileges


    CREATE Database/Granting PrivilegesCREATE your first database Code: [code:1:0668cd8e74]CREATE database myfirstdb; [/code:1:0668cd8e74] CREATE a user for your first database This one creates the user 'sqladmin' and gives them 'usage' on your new database 'myfirstdb' Code: [code:1:0668cd8e74]mysql> GRANT usage on myfirstdb.* to sqladmin@localhost; Query OK, 0 rows affected (0.00 sec)[/code:1:0668........
  • Great sound tutorial


    Great sound tutorialThis is great if you need users to be able to start/stop playing sound on your page with the click of a button. http://www.smartwebby.com/Flash/sound_button.aspHere's a simple one except that it doesn't do rollovers. http://www.flash-here.com/tutorials/flash_play_sound.html I actually could not get the rollovers to work using the other tutorial so it is either a mistake on the webmaster's part or........
  • Live E-mail Verfication


    Live E-mail VerficationTwo very cool tutorials that actually connect to the supposed mail server of whatever address the user specifies to see if the e-mail address actually exists. http://www.devshed.com/c/a/PHP/Email-Address-Verification-with-PHP/ http://www.zend.com/zend/spotlight/ev12apr.php?article=ev12apr&kind=sl&id=1782&open=1&anc=0&view=1#notes........
  • Need identd for port 113 ? Install authd


    Need identd for port 113 ? Install authdyum install authd Happy identing :)Actually it's not that simple. It installs as an "xinetd" service and is disabled and turned off by deafult. To enable it run: [code:1:8c94df8319] chkconfig --level 3 auth on service xinetd restart [/code:1:8c94df8319] This will set identd aka authd to start by default. service xinetd resta........
  • Quick Tutorial On Starting A Web Site


    Quick Tutorial On Starting A Web Site[b:3cef3c01b6]Step 1.[/b:3cef3c01b6] Purchase a Domain Name (eg. yoursite.com) [b:3cef3c01b6]Step 2.[/b:3cef3c01b6] Design your site using a program such as Microsoft Frontpage or Macromedia Dreamweaver. If you are unable or unfamiliar with doing this you may want to hire a company to create your site (many of them will handle each aspect of setting up your site). [b:3cef3c01b6]Step 3.[/b:3cef3c01b6] Host your site........
  • E-Mail Tip


    E-Mail TipI just thought I'd give you guys a good tip about e-mail. It seems a lot of people like to use a Hotmail or ISP (eg. Telus) account for their e-mail but the problem is what happens if you switch ISPs, then your e-mail address no longer works and old friends might not be able to contact you. The same thing has happened for excite.com e-mail addresses where they just shut down. Whether you are a business owner or personal user can you afford to lose an e-mail........
  • The New Chips on the Block


    The New Chips on the BlockThe New Chips on the Block By Bruce Gain Story location: http://www.wired.com/news/infostructure/0,1377,67795,00.html 02:00 AM Jun. 13, 2005 PT We have embarked upon a new era in x86 PC computing -- so say chip giants AMD and Intel following their launches of dual-core PC processors. So how will dual-core processing change your PC computing experience? Our FAQ should help you decide whether or when you sho........
  • Trouble connecting between Windows XP and Windows 98 Shares


    Trouble connecting between Windows XP and Windows 98 SharesOk a few things to check for: * Disable all firewalls * Make sure NetBEUI is enabled on both computers * Make sure the Windows XP computer has the name of the computer logged in user of Windows 98 added as an XP user * Add the XP user to anything you want to share That fixed my problem........
  • Mounting NTFS in Unix


    Mounting NTFS in UnixJust a quick tutorial to mount your NTFS volumes in Unix (FreeBSD/Linux) [quote:4a9de7bf80]mount -t ntfs -o umask=0 /dev/your_partition /mnt/your_mount_point[/quote:4a9de7bf80] [b:4a9de7bf80]-o umask=0[/b:4a9de7bf80] is to ensure all users can access the mounted partition (otherwise don't use it and only root can access the mounted partition) [b:4a9de7bf80]-t ntfs[/b:4a9de7bf80] is simple because it just lets mount kno........
  • PHPBB Drop All Tables


    PHPBB Drop All TablesSQL Syntax: [quote:75acd496c1]drop table phpbb_auth_access, phpbb_banlist, phpbb_categories, phpbb_config, phpbb_confirm, phpbb_disallow, phpbb_forum_prune, phpbb_forums, phpbb_groups, phpbb_posts, phpbb_posts_text, phpbb_privmsgs, phpbb_privmsgs_text, phpbb_ranks, phpbb_search_results, phpbb_search_wordlist, phpbb_search_wordmatch, phpbb_sessions, phpbb_smilies, phpbb_themes, phpbb_themes_name, phpbb_topics, phpbb_topics_watch, phpbb_user_group, p........
  • Intrusion Detection Resources


    Intrusion Detection ResourcesI think this could be very useful even for home users in learning how to secure their networks or even offices. http://www.sans.org/resources/idfaq/........
  • gnuCash - Alternative to Quickbooks/Quicken and other COTS accounting software.


    gnuCash is available for all main platforms, Linux/Unix, MacOS (FreeBSD anyway), and Windows. You can download gnuCash free from here. It does seem to be fairly full featured and somewhat straight forward, but like so many programs it is missing a few key features or things don't work quite right. It doesn't support importation of CSV files, which is a big minus. And the developers rather than wanting to add support have just dec........
  • auth/auth_util.c:make_server_info_sam(840) User nobody in passdb, but getpwnam() fails! - SAMBA/SMB Error How To Fix


    auth/auth_util.c:make_server_info_sam(840) User nobody in passdb, but getpwnam() fails! I never found the solution to this in the web, as usual so Ithought I'd post the fix. In plain English smbd is telling us that the user "nobody" does not exist in /etc/passwd. You can simply add this to your /etc/passwd file like so: nobody:x:65534:65534:nobody:/nonexistent:/sbin/nologin Now SAMBA/smbd should........
  • MySQL Error "ERROR 1045 (28000): Access denied for user"


    This happened with a select statement which writes the result to an external file. I didn't remember the privilege "FILE" must be granted on *.* for this to work successfully, it wasn't actually an authentication issue as it implies since I was already in the SQL prompt and doing the query. SELECT some_id FROM sometable INTO OUTFILE '/tmp/result.txt'........
  • How to Track Down/Find Cause of Linux high disk iowait/wa


    top - 09:34:12 up 2 days, 20:57, 2 users, load average: 1.83, 1.99, 2.03 Tasks: 59 total, 2 running, 57 sleeping, 0 stopped, 0 zombie Cpu(s): 0.3%us, 0.0%sy, 0.0%ni, 0.0%id, 99.7%wa, 0.0%hi, 0.0%si, 0.0%st That 99.7% wa is iowait, it means the server is waiting for a process to complete an IOoperation or in plain English, there is a delay in........
  • Adventures in pre-paid SIM Cards and data GPRS/Edge/3G in China with China Mobile in Shenzhen, Guangzhou, Shanghai, Beijing and other cities


    This really is a difficult and confusing process for non-Mandarin speakers, but here's what I've done and learned so far: You can purchase an "M-Zone" China Mobile pre-paid SIMCard from almost anywhere but I tried to purchase mine from Suning (a large electronics dealer) hoping they would be able to help me or answer my questions but my plan didn't work out at all. At Suning once I found someone who spoke some English they gave me the 55 RMB M-Zone China Mobile P........
  • SAMBA/SMB Share "Write" Access without Delete


    There is a nice mode that Samba supports which you can add to smb.conf create mode=555 This way users can create and write files/directories without deleting (except I believe dirs can be deleted but only if there are no files inside). It's too bad that Linux does not have built-in "write"/"delete" privileges and is something that even Windows 98 can trump.........
  • Unixbench Score with Glusterfs/Openvz & Quad Core Xeon - Updated with GlusterFS 2.0.8 & Optimized Client Config


    The results are still not flattering and are nothing close to native performance. Unless GlusterFS has a "DRBD-like" option to delay writes over the network and to only read from the client side, I don't see how performance can ever improve much more. After doing some client optimizations Iadded more to the score: Start Benchmark Run: Sun Nov 29 00:37:44 PST 2009 00:37:44 up 3 min, 1 user, load average: 0.01........
  • Clustered/Distributed Network Filesystems, Which Ones live up to the hype?


    I've tried to find a good sensible solution to cluster with and each technology has it's pros and cons and there is no perfect solution and I've found a lot of "exaggerations" in the applications, benefits and performance of these different filesystems. DRBD I first started off with DRBD and Ihave to say it does live up to the hype, is quite reliable (although it can be annoying to match up the kernel module and user applications since they must match and whe........
  • Unixbench Score with Glusterfs/Openvz & Quad Core Xeon - Updated with GlusterFS 2.0.8


    You might remember my original GluserFS/OpenVZ benchmark which produced a horrible 29.8 This is the exact same system, but using the latest 2.0.8 (with some small files patch which speeds up performance) you can see it is about 25% faster. I also haven't tuned my config files at all, but there are some settings that should increase performance on small files which I believe i........
  • yum error not working rpmdb: mmap: No such device TypeError: rpmdb open failed


    Loaded plugins: fastestmirror rpmdb: mmap: No such device error: db4 error(19) from dbenv->open: No such device error: cannot open Packages index using db3 - No such device (19) error: cannot open Packages database in /var/lib/rpm Traceback (most recent call last): File "/usr/bin/yum", line 29, in ? yummain.user_main(sys.argv[1:], exit_code=True) File "/usr/share/yum-cli/yummain.py&qu........
  • Unixbench Score with Glusterfs/Openvz & Quad Core Xeon


    This is very disappointing since GlusterFS markets itself as a solution to deploy VPS servers on. On the HNitself I get a Unixbench of about 360. I'm also using an SSH tunnel to secure the communications, but even before that, things seemed very slow. # # # # # # # #####&n........
  • Timezone Change/Updated for Linux/Unix Debian/Fedora/Ubuntu/Centos Change Update Time zone


    In Newer Linux Distros This Way Is Easiest and works on newer versions like Ubuntu, Mint, Fedora, Centos, Debian etc. #if you are missing timedatectl this in newer distros like Ubuntu/Mint/Debian and are using a container like Docker then do "apt install systemd" timedatectl set-timezone America/Vancouver Replace the America/Vancouver with the correct timezone. To see the list you can just type "timedatectl set........
  • sudo: Error dropping capabilities, aborting in Linux Centos 5.3


    For some reason Ikeep getting this error when trying to run a sudo command eg: sudo -u someuser somecommand sudo: Error dropping capabilities, aborting My version of sudo is:sudo-1.6.9p17-3.el5_3.1 and I've heard that version 1.7 fixes everything. The only thing is yum does not think sudo has any update. Iguess the new version has not been committed to the RPM repository yet. This is really a huge and ann........
  • Have an OpenVZ VPS/Linux Virtual Private Server and nothing works right?


    A VPS Server I had just wasn't working right, code that I migrated there just wasn't working. For example, it kept telling me the connection to the database was unsuccessful, halfway through iterating through results it already had. Then I realized it wasn't my code. Ichecked my /proc/user_beancounters and found this: cat /proc/user_beancounters Version: 2.5 uid resource held maxheld barrier limit failcnt........
  • MySQL Restoring And Dumping/Backing UP MySQL Data/Tables/Databases


    Backing MySQL Databases Backing Up/Dumping All Mysql Databases To A Single File mysqldump --all-databases -u admin -p > allmysqldatabases.sql The "-all-databases" clause is pretty obvious isn't it? It means that it will backup all databases. The "-u admin" means login using the user "admin", if you h........
  • iPhone/iPod touch on 3.0 software overheating?


    There have been lots of reports like this going around and Ican confirm my 3GS with 3.0 firmware is overheating as well. It gets quite hot and actually can make your head or hand sweaty when holding it to talk, or simply holding the back cover for any reason. It's a wonder how the device cools itself at all, considering the only thing that could ventilate air are the 2 speakers at the bottom or the single speaker on the front of the device. Apple seems to be making........
  • How to solve the iPhone 15 minute POP/IMAP checking delay option with virtual push


    You need to jailbreak your phone and inside Cydia you'll find "PushMod" which will allow you to set your mail check time to 1 minute instead of 15-minutes. This is a great mod and has saved me a lot of stress and frustration, the lack of Blackberry style "free push service" makes iPhone less attractive, but this solves that. Apple needs to make mobileme free and have a Blackberry style chat network to compete, I'm not willing to pay for something Blackberry........
  • Why Apple should thank the jailbreakers and not patch/stop the jailbreaking exploits


    First of all, the iPhone is crippled in many ways, but most of my complaints about functionality have been addressed through the jailbreak, Ican run apps in the background of my choosing, I can install a terminal, acccess my phone through SSH and SCP and so much more. It even addresses the 15 minute e-mail problem, I installed a program called "PushMod" and now set the checking time to just 1 minute. Apple should really thank the developers for this gift, it ma........
  • iPhone 3GS Jailbreak Information & Benefits


    Truly, the only way to unleash the capabilities and customization abilities of iPhone are to jailbreak, it's not just for hackers anymore. A few days ago someone by the named of "geohot" released a single click application called "purplera1n", which does the entire operation smoothly and seamlessly. In our case, the first time it went as far as "done, wait for reboot" on our Windows machine and for minutes we waited and saw the pic on the iPhone w........
  • iPhone 3GS 32GB "Harsh Review"


    Yes, Iadmit I finally got bitten by the hype as much as I can usually see through it all. Keep in mind this review is of the "stock" phone, no jailbreaking yet which is what really unleashes the customizability and whyI bought iPhone. I had better things to say about this phone before buying it, and it is a great phone, perhaps the best on the market by far, if not because of the Mac OS port onto the iPhone and all the apps, etc, etc. With that said........
  • iPhone has no password/wand manager saving feature in Safari Web Browser


    I kind of expected this feature to be there in some form, to stay ahead of the pack Apple needs to stay on top of this. User's of HTC's Android smart phone which uses a Linux based OS with Google's power behind it, note that you can save passwords in the browser on that phone. Apple needs to continuously evaluate the needs in its core apps and make sure the features are cutting edge and top notch, if other phones come out with some of these seemingly small but essential features........
  • Apple iPhone 3GS and predecessors are leading a revolution


    As much of a computer nerd as Iam, I'm usually a late adopter to technology for a few reasons. Ifeel most new hyped technologies and electronics are mainly fads, and I'm also cheap. Adopting later means you avoid the bugs, kinks and most importantly pay the lowest price, that's me being cheap again :) I never read much about the iPhone but Isaw all the hype around it and until recently I wasn't a big fan of anything Apple until a few years ago I realize........
  • Nokia N97 review, feedback and complaints


    I've had an old Blackberry for a few years and I was ready to spend some serious cash on a nice Nokia. I love the idea of the Linux based Symbian S60 OS, so I was looking at phones like the E63, E71 (both are basically the same, at least CPU/screensize although E71 is thinner, has a 3MP camera, has GPS, and has dedicated buttons to adjust the volume). Then Iheard about the N97 and what a revolution it was supposed to be and it was even compared to iPhone. To........
  • OCFS2 crash


    When trying to even cd or ls the mounted OCFS2 partition it crashes. Ithink this is a combination of VMWare Server's problem and the way I mounted and symlinked to it. More than anything this shows the problem and lack of forsight with VMWare, but also that OCFS2 is easily crashed if you do strange things. Output of /var/log/messages for OCFS2 Apr 10 15:57:45 localhost kernel: [84331.691258] Modules linked in: vmnet vmci vmmon ocfs2_stac........
  • Samba SMB Error - Server not using user level security and no password supplied. tree connect failed: NT_STATUS_WRONG_PASSWORD


    Server not using user level security and no password supplied. tree connect failed: NT_STATUS_WRONG_PASSWORD That happens when trying to use smbclient to connect to a share. The weird thing is that I can authnenticate just fine from Windows XP. It is partially my mistake, I forgot this share does have a password. I've tried authenticating with the correct user and also with "Guest" because this works in Windows. In Linux I ........
  • Viewing and Connecting to an SMB Samba Share on Windows/Linux/Unix


    This will give you the basic info needed to browse and connect to Samba shares from the command line. From the GUI of Gnome or KDE etc, it is pretty standard and straight forward. However, I've found very little guides on how to do it from the command line and if you're like me, a nerd who prefers command line for its simplicity and for remote use, this is the way to go. First get a list of all the Samba/SMB shares on the target. smbclient -L hostname........
  • SSH Problem User username from 127.0.0.1 not allowed because not listed in AllowUsers


    User username from 127.0.0.1 not allowed because not listed in AllowUsers What's going on? The user was created properly, it has been defined as having a shell entry and the entry for /etc/passwd and /etc/shadow is set just fine. This is a new and very smart/secure feature of SSHD. It is simple and yet effective, but also very annoying if you didn't know about it being implemented and that hand editing of /etc/ssh/sshd_config is required to allow a newly add........
  • Writing/Burning a data CD-R/DVD-R or DVD+RW in Unix/Linux


    There's a lot of outdated information and confusion for system administrator's out there. One annoying task for many an Administrator has been backing up data in Linux. You don't need any GUI tools such as K3B or GnomeBaker. Both are excellent tools but for veteran command line users working remotely, using the keyboard is a great and possibly automated way to save yourself pain and hassle. At a later date we'll cover how scripting can automatically backup certain........
  • Latest Articles

  • How To Add Windows 7 8 10 11 to GRUB Boot List Dual Booting
  • How to configure OpenDKIM on Linux with Postfix and setup bind zonefile
  • Debian Ubuntu 10/11/12 Linux how to get tftpd-hpa server setup tutorial
  • efibootmgr: option requires an argument -- 'd' efibootmgr version 15 grub-install.real: error: efibootmgr failed to register the boot entry: Operation not permitted.
  • Apache Error Won't start SSL Cert Issue Solution Unable to configure verify locations for client authentication SSL Library Error: 151441510 error:0906D066:PEM routines:PEM_read_bio:bad end line SSL Library Error: 185090057 error:0B084009:x509 certif
  • Linux Debian Mint Ubuntu Bridge br0 gets random IP
  • redis requirements
  • How to kill a docker swarm
  • docker swarm silly issues
  • isc-dhcp-server dhcpd how to get longer lease
  • nvidia cannot resume from sleep Comm: nvidia-sleep.sh Tainted: Linux Ubuntu Mint Debian
  • zfs and LUKS how to recover in Linux
  • [error] (28)No space left on device: Cannot create SSLMutex Apache Solution Linux CentOS Ubuntu Debian Mint
  • Save money on bandwidth by disabling reflective rpc queries in Linux CentOS RHEL Ubuntu Debian
  • How to access a disk with bad superblock Linux Ubuntu Debian Redhat CentOS ext3 ext4
  • ImageMagick error convert solution - convert-im6.q16: cache resources exhausted
  • PTY allocation request failed on channel 0 solution
  • docker error not supported as upperdir failed to start daemon: error initializing graphdriver: driver not supported
  • Migrated Linux Ubuntu Mint not starting services due to broken /var/run and dbus - Failed to connect to bus: No such file or directory solution
  • qemu-system-x86_64: Initialization of device ide-hd failed: Failed to get