Menambahkan super user di mysql

CREATING ANOTHER SUPER USER

Login ke mysql dengan akses root :
sudo mysql -u root -p
CREATE USER 'newuser'@'localhost' IDENTIFIED BY 'password';
While not particularly secure, in some cases you may wish to create another ‘super user’, that has ALL privileges across ALL databases on the server. That can be performed similar to above, but by replacing the database_name with the wildcard asterisk:
mysql> GRANT ALL PRIVILEGES ON *.* TO 'username'@'%';
Now username has the same privileges as the default root account, beware!

SAVING YOUR CHANGES

As a final step following any updates to the user privileges, be sure to save the changes by issuing the FLUSH PRIVILEGES command from the mysql prompt:
mysql> FLUSH PRIVILEGES;
Query OK, 0 rows affected (0.01 sec)

Ganti port dan seting private key untuk ssh centos 7



Ganti Port
===============================
First Take a backup copy of the existing SSH server configuration :
cp /etc/ssh/sshd_config /etc/ssh/sshd_config.bak
Now Edit the configuration file :
vim /etc/ssh/sshd_config
and change the Port number from 22 to any custom port you choose :
Port 2244
Save the file with :wq!
# If you want to change the port on a SELinux system, you have to tell
# SELinux about this change.
# semanage port -a -t ssh_port_t -p tcp #PORTNUMBER
#
Example Case :
you need to install policycoreutils package to run the semanage command. to do this :
yum -y install policycoreutils-python
now update SeLinux policy to allow new port for SSH service. to do this, run below :
semanage port -a -t ssh_port_t -p tcp 2244
now you need to update Firewall policy to allow new SSH Port, to do this run below :
firewall-cmd --permanent --zone=public --add-port=2244/tcp
firewall-cmd --reload
systemctl restart sshd.service
to Check the service status, run below :
ss -tnlp | grep ssh

Setting Private key
===============================
Once you have access to your account on the remote server, you should make sure the ~/.ssh directory exists. This command will create the directory if necessary, or do nothing if it already exists:
  • mkdir -p ~/.ssh
copykan atau buat file authorized_keys dengan isi public key yang akan di gunakan.

  • vi authorized_keys

Finally, we’ll ensure that the ~/.ssh directory and authorized_keys file have the appropriate permissions set:
  • chmod -R go= ~/.ssh
This recursively removes all “group” and “other” permissions for the ~/.ssh/ directory.
If you’re using the root account to set up keys for a user account, it’s also important that the ~/.sshdirectory belongs to the user and not to root:
  • chown -R sammy:sammy ~/.ssh
In this tutorial our user is named sammy but you should substitute the appropriate username into the above command.
We can now attempt passwordless authentication with our Ubuntu server.
cara login ssh


  • chown -R sammy: sudo ssh -i path_private_key_disimpan -p port user@IP_yang_dituju

error load APCU.SO di WHM


APCU.so versi baru 5.x.x tidak kompatibel untuk PHP 7 kebawah, untuk instal di PHP 5.6 via terminal perintahnya :

/opt/cpanel/ea-php56/root/usr/bin/pecl install channel://pecl.php.net/APCu-4.0.10
sedangkan untuk php 7 :

/opt/cpanel/ea-php70/root/usr/bin/pecl install apcu 

Thing to do after install ubuntu 18.04 LTS


  1. update dan upgrade 
    sudo apt-get update && sudo apt-get upgrade
  2. install theme, favorit saya mac os theme https://www.youtube.com/watch?v=sfsKwzElxQg
  3. Instal atom editor penganti sublime https://linuxconfig.org/install-atom-on-ubuntu-18-04-bionic-beaver-linux
  4. insall mysql workbench 
  5. install wine dan playon https://linuxconfig.org/install-wine-on-ubuntu-18-04-bionic-beaver-linux atau https://hackingsaga.com/easiest-way-install-use-microsoft-office-linux/


The 'grub-efi-amd64-signed' package failed to install Ubuntu 18.04

The 'grub-efi-amd64-signed' package failed to install into /target/. Without the GRUB bootloader, the installed system will not boot.



Solusinya
buat satu partisi lagi pada saat instalasi dengan type ESP or EPS, dengan besar 100-200mb, di rekomendasikan 500mb, kemudian pada pilihan loader pilih lah SDA1 (keseluruhan hardisk) jangan per partisi.  selebihnya lanjutkan seperti instalasi biasa.

Install ubuntu 18.04 LTS


Solusi mudah murah prekaman arsip digital : Perekaman Arsip Kepegawaian