—Install PHPipam

sudo apt-get install apache2

sudo service apache2 restart

apt install libapache2-mod-php php-curl

apt install libapache2-mod-php php-gmp

sudo apt-get install php

sudo a2enmod rewrite

apt-get install mysqld

mysql_secure_installation

ALTER USER ‘root’@’localhost’ IDENTIFIED WITH mysql_native_password BY ‘Passworrd’;

FLUSH PRIVILEGES;

—Create a loopback

ifconfig lo:0 127.0.0.2 netmask 255.0.0.0 up

GUI For LAMP

—-Initialise mysql Installation

sudo mysql_secure_installation utility

–Setup SNMP

snmpconf -g basic_setup

——mount a shared folder

sudo mount -t cifs -o username=raghu //172.29.32.184/sharename /media/Data/

—-Extract zip file

sudo tar zxvf asterisk-15-current.tar.gz

—OpenSSL Config

/usr/lib/ssl/openssl.cnf

—Remove CD-ROM from sources

sudo sed -i ‘/cdrom/d’ /etc/apt/sources.list

—php.ini

/etc/php/5.6/cli/php.ini

2. For apt,software center etc

edit the file /etc/apt/apt.conf

And then replace all the existing text by the following lines

Acquire::http::proxy “http://username:password@host:port/”;

Acquire::ftp::proxy “ftp://username:password@host:port/”;

Acquire::https::proxy “https://username:password@host:port/”;

1. sudo vi /etc/environment

2. http_proxy=”http://<username>:<password>@<hostname>:<port>/”

https_proxy=”http://<username>:<password>@<hostname>:<port>/”

ftp_proxy=”http://<username>:<password>@<hostname>:<port>/”

—Import a DB

sudo mysql -u phpipam -p phpipam < MIGRATE.sql

—DNS Overritting 

/run/systemd/resolve/resolv.conf

–Not able to ping

ping: socket: Operation not permitted

solution

sysctl -w net.ipv4.ping_group_range=”0 1000″

phipam ipam

sudo apt-get install fping

—-Assign an IP by Script

nano /usr/script.sh

ip link set ens34 up

ip address change dev ens34 192.168.1.128/24

ip route add default dev ens34 via 192.168.1.254

make it executable

sudo chmod 777 /usr/script.sh

—-launch script on start up

  • Open the crontab file:crontab -e If it’s your first time in the crontab, you need to select an editor (just press Enter to use Nano).

  • Create a new line starting with @reboot, and add your script command just after, like this:@reboot /home/pat/Desktop/test.shIt’s important to use the full path to your script in this command.The crontab doesn’t know where your script is located on the system drive.
  • Save and exit (CTRL+O, CTRL+X with nano).

Leave a Reply