Default locations of config and sites.
Making a note because I use them just often enough to forget where they are.
apache2 conf location: /etc/apache2/httpd.conf
site location /var/www/html/site-name
lsof -w -n -i tcp:5000
kill -9 processId
stop the server
sudo apachectl stop
primary config file:
/etc/apache2/apache2.conf edit it to have: serverName localhost at the very end of the file
sudo aoachectl start
default root for the apache server (as in what it dispalys in localhost):
/var/www/html/index.html i had drupal setup there so apache is looking inside a folder called drupal for the index.html file so i'm just going to dump shit in there
install php and modules for apache:
sudo apt-get install php libapache2-mod-php php-mysql deprechiated https://askubuntu.com/questions/1031921/php-mcrypt-package-missing-in-ubuntu-server-18-04-lts
turn error display on:
sudo gedit /etc/php/7.2/apache2/php.ini find display_errors = Off change it to On restart apache sudo apachectl restart
install mysql and gui:
sudo apt-get install mysql-server sudo apt-get install mysql-workbench
sudo service mysql status
Run as root:
docker stop $(docker ps -q)
get current driver info:
sudo lshw -c video
configuration: driver=amdgpu latency=0
replace AMDs driver with MESA:
So folloing the advice in the above link i first purged and removed then did
sudo lshw -c video
and it's still using the same driver, so i don't think it's actually using the mesa driver at all
after re-adding the packages it still shows the driver as:
seems the right driver is installed you can check with:
glxinfo | grep "OpenGL version"
says mesa there
The mesa drivers are better but I am still getting graphical problems.
Command to fix problem with wifi dropping on x200
sudo iwconfig wlp3s0 power off
Check the adapter state:
sudo lshw -C network
Make the network connection active:
sudo ifconfig eno1 up
Manually set the ipv4 setting for the ethernet adapter
sudo ifconfig eno1 192.168.0.15 netmask 255.255.255.0
Set the default gateway
sudo route add default gw 192.168.0.1 eno1
Set the defualt nameserver:
echo "nameserver 188.8.131.52" > /etc/resolv.conf
THE ABOVE IS BASICALLY ALL YOU NEED TO GET IT WORKING
i now get permission denied doing the above command even as root, permissions for the file resolv.conf are actually for anyone to be able to edit lrwxrwxrwx 1 root root 39 Jul 1 23:03 resolv.conf -> ../run/systemd/resolve/stub-resolv.conf so it's a little strange, looking at the file the nameserver is: nameserver 127.0.0.53 so i'm changing it to: 184.108.40.206 so trying to save resolv.conf i get: could not save file too many levels of symbolic links a@a-Z97-D3H:/etc$ ls -al | grep resolv.conf lrwxrwxrwx 1 root root 39 Jul 1 23:03 resolv.conf -> ../run/systemd/resolve/stub-resolv.conf i have changed both files in: /run/systemd/resolve to have a name server of: 220.127.116.11
These two are not that useful
lspci -nnk lspci -nnk | grep -A2 net
while sleep 1; do ls | wc -l; done rm -r *.srt ls -alh | grep '\.json$' | sort Search all files for a specific extension: find / -name "*.pdf"
no ethernet networking
not helpful but good for info
lshw -C network sudo service network-manager restart
/etc/NetworkManager/NetworkManager.conf changed managed to true changed it back
still no internet
lspci -nn | grep 0200 00:19.0 Ethernet controller : Intel Corporation Ethernet Connection I217-V [8086:153b]
this did nothing
sudo apt-get install build-essential linux-headers-generic
installed net-tools for ifconfig, why doesn't it have it by default?
it seems like it has the driver, that the driver works but that it just doesn't connect
upgrading ubuntu software packages to see if it helps
this seems to be the driver and this command checks it?
sudo modprobe e1000e
grep of log for adapter
dmesg | grep e100
log says it was renamed:
[ 0.943644] e1000e 0000:00:19.0 eno1: renamed from eth0
this might be the cause of the problem?
tried manually setting ip, netmask dns for ip4 for the adapter, tells me it's connected, guess what it's not connected
ethernet adapter is called eno1 for some reason
downloading driver from intel for
Ethernet controller: Intel Corporation Ethernet Connection I217-V got the info on that from running lspci sudo apt install ethtool
get info on adapter
ethtool adapter_name e.g. ethtool eno1
It is really intermittent though, in using Fedora the same computer has no problems with the network adapter. Like Ubuntu however the sound doesn't work for headphones which is a whole other annoying Gnome3 thing.
See ports in use:
sudo netstat -plnt
Filter the list:
sudo netstat -plnt | grep ':80'
Kill all proccess using a specific port, this will do so violently:
kill -9 $(lsof -t -i:5000)
make sure the service is started:
sudo service mongod start
Reload sound driver in Ubuntu:
pulseaudio -k && sudo alsa force-reload
I've needed to do this on multiple installs far, far too often.