Posted by: Master Will | February 25, 2016

Windows 10 cannot Left click on Start button‏

To fix Windows 10 cannot do left click at start button.

Right click at Start button > select Command Prompt (Admin) > type powershell > press Enter > wait a bit until you see….
PS C:\windows\system32>

At the flashing prompt, copy and paste this( please use Copy and paste to avoid typo)

Get-AppXPackage -AllUsers | Foreach {Add-AppxPackage -DisableDevelopmentMode -Register “$($_.InstallLocation)\AppXManifest.xml“}

> press Enter.

Ignore any error in red.

When finished, try Start button again.

Good luck

Advertisements
Posted by: Master Will | January 20, 2016

Install whm/cPanel

To install cPanel & WHM on your server, run the following command:

cd /home && curl -o latest -L https://securedownloads.cpanel.net/latest && sh latest

 

WHMxtra Install Instructions
Installation notes: Please ensure the following prior to running any installer:

1. Run the below command:

rm -rf xtra.sh;rm -rf cpx.sh;rm -rf pro.sh;rm -rf basic.sh;rm -rf xlite.sh

This will remove any old installer files laying around.

2. Turn off any firewall you may be using, or the installer may not be able to connect to our server to retrieve the proper files.

3. Run the following command to install

Install: wget http://whmxtra.com/pro/pro.sh;sh pro.sh

 

Attracta’s Powerful Tools to Your Customers
wget -N http://www.attracta.com/static/download/cpanel-install
sh cpanel-install

Posted by: Master Will | August 11, 2015

Install suphp on directadmin using custombuild

While managing DirectAdmin server  you might sometime want to change the php handler to suphp instead of default mod_php. Because suphp provides better protection to server than mod_php because it runs the php scripts under the user account instead of default user apache. DirectAdmin custombuild provides a very easy way to do it.

cd /usr/local/directadmin/custombuild/
./build set php5_cgi yes
./build set php5_cli no
./build set ioncube yes
./build all d
./build rewrite_confs

Note: If you just want to upgrade PHP
./build set php5_ver 5.5
./build update
./build php n

service httpd restart

Note: If you just want to build ioncube
cd /usr/local/directadmin/custombuild
./build update
./build ioncube
./build php-ini
service httpd restart

Now after suphp is installed on the server. You will need to fix phpMyAdmin, Roundcube and squirrelmail

./build roundcube
./build squirrelmail
./build phpmyadmin

No you can fix the permissions of all the files and folders of the users.

for i in `/bin/ls /usr/local/directadmin/data/users/` ; do chown -R $i.$i /home/$i/domains/* ; echo $i ;done
for i in `/bin/ls /usr/local/directadmin/data/users/` ; do find /home/$i/domains/ -type f -exec chmod 644 {} \; ; echo $i ;done
for i in `/bin/ls /usr/local/directadmin/data/users/` ; do find /home/$i/domains/ -type d -exec chmod 755 {} \; ; echo $i ;done

Source: http://servermanagementplus.com/linux-server-support/install-suphp-directadmin-using-custombuild

Useful link: http://forum.directadmin.com/showthread.php?t=29824

Posted by: Master Will | June 9, 2015

OpenVZ quota recalculate

vzctl stop 1100

vzquota drop 1100

vzctl start 1100

While starting VE with VEID 200 quota will be recalculated

Purpose

In our base CentOS 6.3 image it uses a few endpoints in the EPEL repos that are set by default that use SSL 3.0. Due to this you will receive the error noted below when attempting to use yum update from the instance. This article will show you how to remedy that while we work on deploying an updated CentOS 6.x image.

 

Loaded plugins: fastestmirror, security
Determining fastest mirrors
Error: Cannot retrieve metalink for repository: epel. Please verify its path and try again.

Notes

We will update this knowledge base article once we have an updated and fixed CentOS 6.x image.

The CentOS 5.8 and CentOS 7 images available to use don’t have this issue.

Walkthrough Steps

Running this command will update the repo to use HTTP rather than HTTPS:

sudo sed -i "s/mirrorlist=https/mirrorlist=http/" /etc/yum.repos.d/epel.repo

You should then be able to update with this command:
yum -y update


Source: https://community.hpcloud.com/article/centos-63-instance-giving-cannot-retrieve-metalink-repository-epel-error


					
Posted by: Master Will | March 5, 2015

How can I determine what is taking up so much space?

1. Use linux command
du -hscx *

2. Write shell script
------------------------------------------
#!/bin/bash

if [ "$1" == "-b" ] ;then
    shift
    export units=(b K M G T P)
    export duargs="-xbs"
    export minsize=${2:-$((256*1024**2))}
else
    export units=(K M G T P)
    export duargs="-xks"
    export minsize=${2:-$((256*1024))}
fi

humansize() {
    local _c=$1 _i=0
    while [ ${#_c} -gt 3 ] ;do
    ((_i++))
    _c=$((_c>>10))
    done
    _c=$(( ( $1*1000 ) >> ( 10*_i ) ))
    printf ${2+-v} $2 "%.2f%s" ${_c:0:${#_c}-3}.${_c:${#_c}-3} ${units[_i]}
}

export device=$(stat -c %d "${1:-.}")

rdu() {
    local _dir="$1" _spc="$2" _crt _siz _str
    while read _siz _crt;do
        if [ $_siz -gt $minsize ];then
        humansize $_siz _str
        printf "%s%12s%14s_%s\n" "$_spc" "$_str" \\ "${_crt##*/}"
        [ -d "$_crt" ] &&
        [ $(stat -c %d "$_crt") -eq $device ] &&
            rdu "$_crt" "  $_spc"
    fi
    done < <(
    find "$_dir" -mindepth 1 -maxdepth 1 -xdev \
        \( -type f -o -type d \) -printf "%D;%p\n" |
        sed -ne "s/^${device};//p" |
        tr \\n \\0 |
        xargs -0 du $duargs |
        sort -nr
    )
}

rdu "${1:-.}"
------------------------------------------
Usage:
./rdu.sh /usr 100000000
       1.53G             \_lib
       143.52M             \_i386-linux-gnu
       348.16M             \_x86_64-linux-gnu
       107.80M             \_jvm
         100.20M             \_java-6-openjdk-amd64
           100.17M             \_jre
              99.65M             \_lib
       306.63M             \_libreoffice
         271.75M             \_program
       107.98M             \_chromium
      99.57M             \_lib32
     452.47M             \_bin
       2.50G             \_share
       139.63M             \_texlive
         129.74M             \_texmf-dist
       478.36M             \_locale
       124.49M             \_icons
       878.09M             \_doc
         364.02M             \_texlive-latex-extra-doc
           359.36M             \_latex

3. Use utility named "ncdu" that download at http://dev.yorhel.nl/ncdu
Sample output
ncdu 1.7 ~ Use the arrow keys to navigate, press ? for help                                                         
--- /data ----------------------------------------------------------------------------------------------------------
  163.3GiB [##########] /docimages                                                                                  
   84.4GiB [#####     ] /data
   82.0GiB [#####     ] /sldata
   56.2GiB [###       ] /prt
   40.1GiB [##        ] /slisam
   30.8GiB [#         ] /isam
   18.3GiB [#         ] /mail
   10.2GiB [          ] /export
    3.9GiB [          ] /edi   
    1.7GiB [          ] /io     
    1.2GiB [          ] /dmt
  896.7MiB [          ] /src
  821.5MiB [          ] /upload
  691.1MiB [          ] /client
  686.8MiB [          ] /cocoon
  542.5MiB [          ] /hist
  358.1MiB [          ] /savsrc
  228.9MiB [          ] /help
  108.1MiB [          ] /savbin
  101.2MiB [          ] /dm
   40.7MiB [          ] /download
 
Posted by: Master Will | February 23, 2015

OpenVPN easy script for CentOS, Ubuntu, Debian

VPN Server:

wget git.io/vpn –no-check-certificate -O openvpn-install.sh; bash openvpn-install.sh

After installed,

then save it with .ovpn extension.

Save that file in the config directory of where you installed OpenVPN client in your local computer.

 

VPN Client:

Download windows version at http://assets.unotelly.com/downloads/apps/windows/openvpn-client.msi

Install and load .ovpn into VPN client

Done.

 

Link:

Server: https://github.com/Nyr/openvpn-install

Client: http://help.unotelly.com/support/articles/184301-openvpn-desktop-client-setup-windows-

Posted by: Master Will | October 18, 2014

How to change Charset in ORACLE

At server side:
You can change database character set by doing the following steps.

In this case SID name is fujudb. (Check at TNSNAME.ORA)

Login to oracle Database server as sys privilege

SQLPLUS> connect sys/syspassword@fujudb as sysdba;

SQLPLUS> shutdown immediate;
SQLPLUS> startup mount;

SQLPLUS> alter system enable restricted session;
SQLPLUS> alter system set job_queue_processes=0;
SQLPLUS> alter system set aq_tm_processes=0;
SQLPLUS> alter database open;
SQLPLUS> alter database ORCL character set TH8TISASCII;
OR
SQLPLUS> connect sys/syspassword@fujudb as sysdba;
SQLPLUS> update prop$ set value$ = ‘TH8TISASCII’ where name=’NLS_CHARACTERSET’;
To Check DATBASE Charset
SQLPLUS> SELECT * FROM NLS_DATABASE_PARAMETERS;
NLS_CHARACTERSET = TH8TISASCII
NLS_NCHAR_CHARACTERSET = AL16UTF16
At client side:
Edit Registry
Regedit > HKEY_LOCAL_MACHINE > Software > Oracle > Home0(KEY_OraDb10g_home1) > NLS_LANG
Change NLS_LANG => THAI_AMERICA.TH8TISASCII
Posted by: Master Will | September 15, 2014

How To Set Up vsftpd on CentOS 6

#yum install vsftpd
#vi /etc/vsftpd/vsftpd.conf
Change to:
anonymous_enable=NO
local_enable=YES
chroot_local_user=YES

Save and Exit
#service vsftpd restart
#chkconfig vsftpd on

Note: If iptables is enabled, then
#modprobe -i ip_conntrack_ftp

To make it start at boot time
#vi /etc/sysconfig/iptables-config 
IPTABLES_MODULES="nf_conntrack_ftp"
 
 
Posted by: Master Will | September 11, 2014

Installing a VPS Node with Flashcache (SolusVM and OpenVZ)

The following guide will help you install a VPS Node with flashcache using SolusVM for OpenVZ.
We will be using the net install iso for this guide. I will also use nano over vi in the guide, you can choose any text editor you wish. Everything in the guide is preformed as root.

Recommended System Requirements:

E3 or Better CPU
32GB of ram or more
4x 1TB Sata Drives on a Raid card with Sata 3 ports on a Raid 10 array.
1x SSD 120GB On a sata 3 port on your motherboard

Configure your Raid card for a raid 10 array. Please see your manufacturer website for additional information on that.

Either burn or mount the netinstall centos 6 x86_64 iso as you would normally to install the OS

NOTE: Centos 6 Net install URL: http://mirror.centos.org/centos/6/os/x86_64/

This is the standard partitioning scheme i used when creating VPS nodes and it works quite well.

Partitions:
/swap ram+2GB
/boot 200MB
/ 20-30GB
/vz rest

When installing CentOS i would recommend choosing base install over minimal. It will save you time for little things you are looking for in the future.

Once you have the OS installed run the following.

yum update -y
reboot -n

Wait for the system to download any updates it can and restart. This is to make sure everything is up to date.

Change the SSH Port:

nano /etc/ssh/sshd_config
Uncomment #Port 22 and replace 22 with any port you wish. (Do not choose a port SolusVM or any other service you install might need as it will make a conflict)
Press CTRL + X and save the changes
service sshd restart
Your ssh connection will now end and you will need to reconnect using the new port you have specified in sshd_config.

Turning off SELinux

nano /etc/selinux/config
Change the directive to disabled.
CTRL + X and save the changes.

Installing SolusVM

wget http://soluslabs.com/installers/solusvm/install
chmod 755 install
./install

Follow the steps to setup your first node as a master or a slave OpenVZ.
I recommend choosing Automatic location to make sure you get the best possible speed downloading the files.
After this has completed please make note of your output. It will contain important information such as your username/password, url:ports, Solusvm ID and Password. Please copy and paste this as you will need this information later.

Once complete reboot the server again.

reboot -n

Once logged back in make sure the OpenVZ kernel loaded

uname -r

You should recieve an output like the following:

2.6.32-042stab075.10

Install Git and Dependents:

yum -y install git dkms gcc make yum-utils kernel-devel

Download and install your kernel devel:

cd /tmp
wget http://download.openvz.org/kernel/branches/rhel6-2.6.32/042stab075.2/vzkernel-devel-2.6.32-042stab075.10.x86_64.rpm (Note: Check the url and replace the file information to match your uname -r output!)
yum -y localinstall vzkernel-devel-2.6.32-042stab075.10.x86_64.rpm

Git Clone Flashcache:

git clone https://github.com/facebook/flashcache.git

Install and Configure Flashcache (Note: Please remember to change the versions to match your uname -r output!)

cd flashcache/
make KERNEL_TREE=/usr/src/kernels/2.6.32-042stab075.10
make install KERNEL_TREE=/usr/src/kernels/2.6.32-042stab075.10
modprobe flashcache
Make sure its running: dmesg | tail

Making /vz flashcached:
umount /vz
Find your UUID for /vz: grep “/vz” /etc/fstab
flashcache_create -p back vz_cached /dev/sdb /dev/disk/by-uuid/replace-with-your-uuid
Comment out vz in fstab: nano /etc/fstab

Configuring Flashcache

Copy the config file: cp /tmp/flashcache/utils/flashcache /etc/init.d
Change the permissions: chmod 755 /etc/init.d/flashcache
nano /etc/init.d/flashcache

Change the following information:

SSD_DISK=/dev/sdb
BACKEND_DISK=/dev/disk/by-uuid/replace-with-your-uuid
CACHEDEV_NAME=vz_cached
MOUNTPOINT=/vz
FLASHCACHE_NAME=vz_cached
CTRL +X and save it.

Turn on Flashcache at boot: chkconfig flashcache on
Reboot the Server: reboot -n

Make sure everything looks good and run df-h.

Do a DD test to make sure flashcache is working.

First do a DD test in the root directory:
cd /
dd if=/dev/zero of=test bs=64k count=16k conv=fdatasync; unlink test

Note the output

Now do a DD test in the /vz directory.
cd /vz
dd if=/dev/zero of=test bs=64k count=16k conv=fdatasync; unlink test

Note awesomeness.

Everything is now setup as far as the base system with SolusVM OpenVZ and Flashcache!

If you have any issues or questions please post below and I will address them as best as possible.

Thank you,

 

Credit: http://www.allvpsinfo.com/discussion/6/installing-a-vps-node-with-flashcache-solusvm-and-openvz/p1

« Newer Posts - Older Posts »

Categories