How to Install clamav on Ubuntu 14.04
Category: Ubuntu
How to Update and Upgrade Ubuntu
# apt-get update
# apt-get upgrade
sudo nano /etc/network/interfaces
# This file describes the network interfaces available on your system # and how to activate them. For more information, see interfaces(5). # The loopback network interface auto lo iface lo inet loopback auto eth0 iface eth0 inet static address ipAddress netmask 255.255.255.0 gateway gatewayIP dns-nameservers 69.64.66.11 69.64.66.10
Once you have entered the values correctly, press Ctrl+Enter to save it with the current filename, then press Ctrl+X to exit the editor.
Provided you entered your values correctly, verify the new settings by retyping the cat command:
cat /etc/network/interfaces # This file describes the network interfaces available on your system # and how to activate them. For more information, see interfaces(5). # The loopback network interface auto lo iface lo inet loopback auto eth0 iface eth0 inet static address 123.45.67.89 netmask 255.255.255.0 gateway 123.45.67.1 dns-nameservers 8.8.8.8 8.8.4.4
Apply setting to Interface
After you have determined the values entered are correct, restart networking with the following command:
sudo service networking restart stop: Unknown instance: networking stop/waiting administrator@ubuntu:~#
Verify it works
To verify the resolvers are working, simply ping a known domain.
ping google.com PING 8.8.8.8 (8.8.8.8) 56(84) bytes of data. 64 bytes from 8.8.8.8: icmp_req=1 ttl=45 time=42.1 ms 64 bytes from 8.8.8.8: icmp_req=2 ttl=45 time=42.2 ms 64 bytes from 8.8.8.8: icmp_req=3 ttl=45 time=42.0 ms
To install ntp on Ubuntu, Linux or debian based distribitions
# apt-get update # apt-get install ntp
To install ntp on Fedora, Centos or redhat based distribitions
# yum install ntp After you set your timezone correcly, you should be able to synce your date and time with ntp command
# ntpdate pool.ntp.org
# ntpdate 0.ubuntu.pool.ntp.org 19 Feb 18:42:09
You can edit the file /etc/ntp.conf to control certain variables with the NTP service, and can start and stop the file using “/etc/init.d/ntp [status|start|stop]”.
A very serious security problem has been found and patched in the GNU C Library called Glibc. It was announced on 27th January 2015.
Here are the affected Linux distros:
- RHEL (Red Hat Enterprise Linux) version 5.x, 6.x and 7.x
- CentOS Linux version 5.x, 6.x & 7.x
- Ubuntu Linux version 10.04, 12.04 LTS
- Debian Linux version 7.x
- Linux Mint version 13.0
- Fedora Linux version 19 or older
- SUSE Linux Enterprise 11 and older (also OpenSuse Linux 11 or older versions).
- SUSE Linux Enterprise Software Development Kit 11 SP3
- SUSE Linux Enterprise Server 11 SP3 for VMware
- SUSE Linux Enterprise Server 11 SP3
- SUSE Linux Enterprise Server 11 SP2 LTSS
- SUSE Linux Enterprise Server 11 SP1 LTSS
- SUSE Linux Enterprise Server 10 SP4 LTSS
- SUSE Linux Enterprise Desktop 11 SP3
- Arch Linux glibc version <= 2.18-1
Read More to Fix the GHOST vulnerability on a CentOS/RHEL/Fedora/Ubuntu Linux
How to reset the mysql password on a linux server.
CentOS
First, stop the MySQL service/daemon. On Centos/RHEL you would run:
# service mysqld stop
Next, edit the MySQL config file (/etc/my.cnf on CentOS/RHEL) and add the following to the [mysqld] section.
# skip-grant-tables
Start MySQL back up
# service mysqld start
You will now be able to connect as user root without any password.
Run the following SQL queries:
mysql> UPDATE mysql.user SET Password=PASSWORD('MyNewPass') WHERE User='root'; FLUSH PRIVILEGES;
Remove the skip-grant-tables line from the MYSQL config file, and restart MySQL one final time.
Ubuntu 16
First off stop mySQL
# sudo service mysql stop
Now manually create the socket directory for MySQLD to be able to start up and give mysql permissions to it. (THIS is the most important step that all guides fail to mention leading people into doing very stupid thing when they cannot get mysqld to start)
# sudo mkdir /var/run/mysqld; sudo chown mysql /var/run/mysqld
Now start mysql with the –skip-grant-tables option because you are not checking user privs at this point
# sudo mysqld_safe --skip-grant-tables &
Now log into mysql as root
# sudo mysql -u root
Now run the following commands in the mysql console
mysql> use mysql; mysql> FLUSH PRIVILEGES; mysql> SET PASSWORD FOR root@'localhost' = PASSWORD('yournewpassword'); mysql> FLUSH PRIVILEGES; mysql> exit
Now stop mySQL and Restart it
# sudo service mysql stop # sudo service mysql start
or
# sudo /etc/init.d/mysql stop # sudo /etc/init.d/mysql start
Check if mySQL started properly by running
# sudo service mysql status
Now to make sure everything is OK reboot your server and after reboot run
# sudo service mysql status
Now you can test logging into mySQL with your new password by running
# mysql -u root -p
Here is how to add additional IP’s to your Ubuntu server
Add it to the server just on a temporary basis. A reboot will erase the changes.
Using ifconfig
If you want to add a secondary IP address to a NIC already in use in Linux, and have that change only temporary. Enter this command:
# ifconfig [nic]:0 [IP-Address] netmask [mask] up
Example:
#ifconfig eth0:0 192.168.1.2 netmask 255.255.255.0 up
If you prefer to use the ip command instead of ifconfig
# ip address add [ip]/[mask-digits] dev [nic]
IP command example
#ip address add 192.168.99.37/24 dev eth0
With this command you can add more ip address to the same NIC, the second is considered as secondary.
Add a permanent IP address to the Server
For Ubuntu systems, edit the /etc/network/interfaces file
# nano /etc/network/interfaces
Example:
auto eth0:1 iface eth0:1 inet static address 192.168.0.1 gateway 192.168.0.254 netmask 255.255.255.0
The restart networking for the changes to take effect
~# service networking restart * Reconfiguring network interfaces...
Check to see if the IP’s re enabled
# ifconfig
You should see the additional IP’s here
You can add What you need. Just change eth0:1 for eth0:2, eth0:3 etc. This can also be done for any other network cards like eth1, eth2, etc.
If the network show this:
# nano /etc/network/interfaces
# This file describes the network interfaces available on your system # and how to activate them. For more information, see interfaces(5). # The loopback network interface auto lo iface lo inet loopback auto em1 iface em1 inet static address 162.xx.xx.xx netmask 255.255.255.0 gateway 162.xx.xx.1 broadcast 162.xx.xx.255 dns-nameservers 8.8.4.4
Add this
auto em2 iface em1 inet static address 10.156.1.xxx netmask 255.255.255.224
Open the Ubuntu Software center
http://www.liveperson.com
Linux
http://solutions.liveperson.com/agent-console/launch/lpac_frame.html
Windows
http://agent.liveperson.net/LPAC/INSTALLER/GA/LPAC_WIN.exe
Mac
http://agent.liveperson.net/LPAC/INSTALLER/GAEA/LPAC_OSX.dmg
(Complete the form with your login credentials & Log in)
My Liveperson Agent Console Download
cd ~/Downloads javaws LPAC-GA.jnlp
To get started, search for and install network-manager-vpnc package from Ubuntu Software Center. Or, do a:
sudo apt-get install network-manager-vpnc
Once installed, you can follow below steps to setup Cisco VPN for Ubuntu:
1.) Move your cursor to right-top corner system tray area, click on Network Manager icon and choose VPN Connections -> Configure VPN
2.) In next window, click on Add button to add a new connection and then choose Cisco Compatible VPN (vpnc) from the drop-down menu.
3.) Click on Create and you’re able to type in your Cisco VPN details in next window. After all, check off “Use this connection only for resources on its network” otherwise your traffic significantly slowed down
Have a PCF File?
cd /etc/vpnc mv default.conf default.conf.bk
Now convert the pcf file:
pcf2vpnc namofpcffile.pcf default.conf
Then to run it, you simply do
sudo vpnc /path/to/new.conf
It’s probably better to have your DNS server be able to resolve ‘puppet’ to the right address, and either to have your DHCP server hand out the DNS nameserver address and search list or else (if you have static IP addresses) to have something like the following in /etc/network/interfaces.
iface eth0 inet static
address 192.168.3.3
netmask 255.255.255.0
gateway 192.168.3.1
dns-search example.com
dns-nameservers 192.168.3.45 192.168.8.10
But if you do want to do it via the resolvconf configuration files you will want to edit /etc/resolvconf/resolv.conf.d/base. In that file, put in your info as you would in resolv.conf.
nameserver 192.168.1.XXX
Then tell resolvconf to regenerate resolv.conf.
sudo resolvconf -u