Professional Documents
Culture Documents
Linux Fundamentals PDF
Linux Fundamentals PDF
In linux:
/proc/kcore
String output and then read into file to find all the text entered in the system
after reboot….
chroot()
chdir()
get_clocktime() only system call from user space itself doest involve kernelspace.
Conatiner: Unshare in linux..-to invoke new namespace ,to insulate from all the
other processes.
Kill -9 procid
NUMA architecture
vim/linux shortcuts/commands:
Uncommenting #:
1. visually select the text as before (or type gv to re-select the previous
selection)
2. :norm x
This deletes the first character of each line. If I had used a 2-char comment such
as // then I'd simply do :norm xx to delete both chars.
:%s/foo/bar/g
https://tournasdimitrios1.wordpress.com/2011/02/22/setup-tftp-server-on-centos/
https://linuxize.com/post/how-to-stop-and-disable-firewalld-on-centos-7/
cat /etc/xinetd.d/tftp
service tftp
{
socket_type = dgram
protocol = udp
wait = yes
user = root
server = /usr/sbin/in.tftpd
server_args = -s /var/lib/tftpboot
disable = no
per_source = 11
cps = 100 2
flags = IPv4
}
Global structure
Int a=0;
Int b=0;
Writer upadews. a+=10,b=a+5 in a loop with sleep of 5 sec and reader will
read(print) structure and sleep for 10 sec.
Locking the data structure— so that read always prints correct values.
✅
Also Implement the structure to be in shared memory using two independent threads.
Done ✅
And now do malloc inside the while loop with sleep and now observer the same
memory file and observe the difference.
Declare global, static ,malloc pointers and observe where they will be with respect
to above memory file.
Try to overutizie malloced memory and compare last address overutilizing against
the memory map.
malloc(20)
Do a shared memory attached to while loop program and print shared memory attached
address;. Done ✅