Professional Documents
Culture Documents
Linux Kurs
Linux Kurs
chown Change owner, change the user and/or group ownership of each given File to a
new Owner. Chown can also change the ownership of a file to match the user/group of an
existing reference file.
make
Raspakivanje sourca:
sudo tar -xf linux-2.6.26.3.tar.bz2 ili bez sudo ako ne zelimo da dobijemo lokovan folder.
Dodavanje u path (svejedno je gdje se nalazimo):
export PATH=/mnt/labs/mips-toolchain/usr/bin/:$PATH
export LD_LIBRARY_PATH=/mnt/labs/mips-toolchain/usr/lib/:$LD_LIBRARY_PATH
u Makefile-u mijenjamo:
ARCH ?= mips
CROSS_COMPILE
?= mips-linux../ - vraca se u kernel
.ko kernel object file
cp linux<verzija>.config .config
sudo cp qemu-ifup /usr/bin/qemu-ifup
sudo cp qemu-isdown /usr/bin/qemu-ifdown
sudo apt-get install nfs-kernel-server
sudo cp exports /etc/exports
qemu:
Instaliranje qemu-a:
qemu-kvm-extras
df_andi pustanje demo u qemuu (pingvini se krecu po povrsini)
sudo apt-get install
Pravljenje PATCH-a:
<folder u kom je linux> - rsync -a linux-<verzija>/ linux-<verzija>-patch
<folder linux<verzija>> - make distclean brise objektne fajlove
<folder u kom je linux> - diff -Nurp linux-<verzija>/ linux-<verzija>-patch/ > patchfile
rsync (Remote Sync) is a most commonly used command for copying and synchronizing
files and directories remotely as well as locally in Linux/Unix systems. With the help of rsync
command you can copy and synchronize your data remotely and locally across directories,
across disks and networks, perform data backups and mirroring between two Linux machines.
make distclean Additionally erase anything ./configure created.
diff Display the differences between two files, or each corresponding file in two
directories. Each set of differences is called a "diff" or "patch". For files that are identical, diff
normally produces no output; for binary (non-text) files, diff normally reports only that they are
different.
pdflush promjene koje su se desile na memoriji da flesuje na disk
PRIORITETI:
-20(maximum); 19(minimum)
-ako zelimo da zadamo prioritet to mozemo samo iz root-a
insmod src/hello_version.ko ispisuje minor i major brojeve (ucitava modul)
rmmod hello_version (uklanja modul iz Linux Kernela)
ls -la dev echo ispisuje sta se nalazi u echo
cat dev/echo ispisuje ono sto se nalazi u echo
dd if=/dev/zero of=naziv_image_fajla.img bs=1M count=64 Kreiranje image diska (64MB
fajl)
mkfs.ext2 -F naziv_image_fajla.img Formatiranje disk imagea u ext2 format
sudo mount -o loop t ext2 <image fajl> <putanja do image fajla> - mountovanje image fajla