Notepad:Linux: Difference between revisions

From Amar
Jump to navigationJump to search
Line 68: Line 68:
* Yum install with missing deps
* Yum install with missing deps
  rpm -Uvh --nodeps $(repoquery --location <module>)
  rpm -Uvh --nodeps $(repoquery --location <module>)
* [[Notepad:LVM Snapshot| LVM Snapshot]]
 
* [https://www.linuxquestions.org/questions/slackware-14/how-to-configure-iptables-for-router-with-2-public-ip-addresses-4175618196/ Example routing iptables firewall]
* [https://www.linuxquestions.org/questions/slackware-14/how-to-configure-iptables-for-router-with-2-public-ip-addresses-4175618196/ Example routing iptables firewall]
* [[Notepad:Disable IPv6 | Disable IPv6]]
* [[Notepad:Disable IPv6 | Disable IPv6]]
Line 81: Line 81:
   ip -br l | awk '$1 !~ "lo|vir|eth" { print $3 }'
   ip -br l | awk '$1 !~ "lo|vir|eth" { print $3 }'


== LVM Expand ==
== LVM ==
=== LVM Expand ===
Expand the physical size
Expand the physical size
  gparted
  gparted
Line 88: Line 89:
Resize the file system
Resize the file system
  resize2fs /dev/vg.../lv...
  resize2fs /dev/vg.../lv...
 
=== [[Notepad:LVM Snapshot| LVM Snapshot]] ===


{{notepad}}
{{notepad}}

Revision as of 17:25, 2 June 2023

Linux Tips and Tricks

Linux stuff I often have to lookup. Just my personal list of things.


shutdown -rF now
xauth add `hostname`/unix:0 . `openssl rand -hex 32`
  • yum versionlock - allows to lock an rpm
  • install faster random for dns etc.
 yum install haveged;
 systemctl enable haveged;
 systemctl start haveged
sudo visudo -f /mnt/etc/sudoers
netstat -tulpn
xargs yum -y install < file
  • Create Default Home Directory
mkhomedir_helper username
use tmpfiles.d and have your package create at startup or boot a file or directory /usr/lib/tmpfiles.d/mydaemon.conf :
man tmpfiles.d

#Type Path            Mode UID      GID    Age Argument
d     /run/mydaemon   0755 myuser myuser   -   -
rpm -Uvh --nodeps $(repoquery --location <module>)
  sudo journalctl --vacuum-time=3weeks
  ip -br l | awk '$1 !~ "lo|vir|eth" { print $3 }'

LVM

LVM Expand

Expand the physical size

gparted

Expand the logical volume

lvextend -l +100%FREE /dev/vg.../lv....

Resize the file system

resize2fs /dev/vg.../lv...

LVM Snapshot


← Back to Notepad



<insert>googlesearchwiki</insert> <insert>paypal</insert> <insert>analytics</insert>