BASH_VERSINFO A readonly array variable

commandline session

$ 4.2.36 2 501---> echo BASH_VERSINFO[0]
BASH_VERSINFO[0]
$ 4.2.36 3 502---> echo $BASH_VERSINFO[0]
4[0]
$ 4.2.36 4 503---> echo $BASH_VERSINFO
4
$ 4.2.36 5 504---> echo $BASH_VERSINFO[1]
4[1]
$ 4.2.36 6 505---> echo BASH_VERSINFO[1]
BASH_VERSINFO[1]
$ 4.2.36 7 506---> echo "BASH_VERSINFO[1]"
BASH_VERSINFO[1]
$ 4.2.36 8 507---> echo BASH_VERSINFO(1)
bash: syntax error near unexpected token `('
$ 4.2.36 8 508---> echo BASH_VERSINFO[4]
BASH_VERSINFO[4]
$ 4.2.36 9 509---> echo $BASH_VERSINFO[4]
4[4]
$ 4.2.36 10 510---> echo ?BASH_VERSINFO[4]
?BASH_VERSINFO[4]
$ 4.2.36 11 511---> echo !BASH_VERSINFO[4]
bash: !BASH_VERSINFO[4]: event not found
$ 4.2.36 11 511---> echo ?BASH_VERSINFO[4]
?BASH_VERSINFO[4]
$ 4.2.36 12 512--->

sar – Collect, report, or save system activity information

commandline session

$ 4.2.36 24 220---> sar -b 1 3
Linux 3.2.0-3-amd64 (debian) 	Saturday 29 September 2012 	_x86_64_	(1 CPU)

01:22:03  IST       tps      rtps      wtps   bread/s   bwrtn/s
01:22:04  IST      0.00      0.00      0.00      0.00      0.00
01:22:05  IST      0.00      0.00      0.00      0.00      0.00
01:22:06  IST      5.21      0.00      5.21      0.00   2541.67
Average:         1.71      0.00      1.71      0.00    832.76
$ 4.2.36 25 221--->
$ 4.2.36 25 221---> sar -b 2 3
Linux 3.2.0-3-amd64 (debian) 	Saturday 29 September 2012 	_x86_64_	(1 CPU)

01:28:41  IST       tps      rtps      wtps   bread/s   bwrtn/s
01:28:43  IST      2.55      0.00      2.55      0.00    600.00
01:28:45  IST      0.00      0.00      0.00      0.00      0.00
01:28:47  IST      0.00      0.00      0.00      0.00      0.00
Average:         0.85      0.00      0.85      0.00    199.66
$ 4.2.36 26 222--->

tcpdump not port 80

commandline session

root@debian:~# tcpdump -i wlan0
tcpdump: verbose output suppressed, use -v or -vv for full protocol decode
listening on wlan0, link-type EN10MB (Ethernet), capture size 100535 bytes
23:33:46.824172 IP debian.local.48247 > mars.infoclub.in.http: Flags [S], seq 1276297543, win 14600, options [mss 1460,sackOK,TS val 4098743 ecr 0,nop,wscale 5], length 0
23:33:46.826612 IP debian.local.41745 > 192.168.0.1.domain: 43954+ PTR? 18.210.22.46.in-addr.arpa. (43)
23:33:46.827744 IP 192.168.0.1.domain > debian.local.41745: 43954 1/0/0 PTR mars.infoclub.in. (73)
23:33:46.828480 IP debian.local.35494 > 192.168.0.1.domain: 55325+ PTR? 101.0.168.192.in-addr.arpa. (44)
23:33:46.873207 IP 192.168.0.1.domain > debian.local.35494: 55325 NXDomain 0/0/0 (44)
23:33:46.975881 IP6 fe80::217:3fff:fed4:5a91.mdns > ff02::fb.mdns: 0 PTR (QM)? 101.0.168.192.in-addr.arpa. (44)
^C23:33:46.976095 IP debian.local.mdns > 224.0.0.251.mdns: 0 PTR (QM)? 101.0.168.192.in-addr.arpa. (44)

7 packets captured
54 packets received by filter
17 packets dropped by kernel
root@debian:~# tcpdump -i wlan0 not port 80
tcpdump: verbose output suppressed, use -v or -vv for full protocol decode
listening on wlan0, link-type EN10MB (Ethernet), capture size 100535 bytes
23:34:05.296866 IP6 fe80::5ed9:98ff:fe5c:11a > ip6-allnodes: ICMP6, router advertisement, length 64
23:34:05.298404 IP debian.local.57548 > 192.168.0.1.domain: 1135+ PTR? a.1.1.0.c.5.e.f.f.f.8.9.9.d.e.5.0.0.0.0.0.0.0.0.0.0.0.0.0.8.e.f.ip6.arpa. (90)
23:34:05.301770 IP 192.168.0.1.domain > debian.local.57548: 1135 NXDomain 0/0/0 (90)
23:34:05.304101 IP debian.local.39053 > 192.168.0.1.domain: 17175+ PTR? 1.0.168.192.in-addr.arpa. (42)
23:34:05.543073 ARP, Request who-has debian.local tell 192.168.0.1, length 28
23:34:05.543107 ARP, Reply debian.local is-at 00:17:3f:d4:5a:91 (oui Unknown), length 28
^C23:34:08.676445 IP 192.168.0.1.2048 > 239.255.255.250.1900: UDP, length 280

7 packets captured
30 packets received by filter
0 packets dropped by kernel
root@debian:~#

money related

I DO NOT GET MONEY BECAUSE…

  • I DO THINGS SLOWER THAN OTHERS
  • I DO THINGS THAT ARE IMPORTANT ONLY TO A FEW
  • I MAINLY DO THINGS FOR MYSELF
  • I WANT TO WORK FOR THE THINGS I WANT TO WORK AND BECOME THE MAN I WANT TO BECOME
  • IAM TYPICALLY WITH THE RIGHT TALENT IN THE WRONG PLACE
  • I USE RIGHT TALENT IN WRONG TIMES

backup

.righthalf
{
position:relative;
left:51%;
top:10.1%;
}

Work Style I

1. Get Topic From The Community
2. Select Easy Or Interested  Area From The Topic
3. Play With It.
4. Organize.
5. Make Connection Between Works(Posts) To Make A Beautiful Work.

Work Style II

1. Topic Selected By Us using Feedback.
2. Select Easy Or Interested  Area From The Topic
3. Play With It.
4. Organize.
5. Make Connection Between Works(Posts) To Make A Beautiful Work.

Content Organization and Architecture

Beautiful Work Tools

Learn and Develop the basic tools that is
part of an operating system.

Debian Research

In order of Priority

+ Building knowledge from data of open source software.
– Knowledge Search and Organization.
– Develop Software for KSAO

+ Integrating data from multiple open sources.

trueangle. open source music

+ Learning Music using open source technology and methods.
Music files here are only for not to profit academic use.

Linux Kernel Development

Learn and Develop Linux Kernel Using
System Administration.

semantic patch using coccinelle

commandline session

$ 4.2.36 26 525---> cat source.c
 #include 

int
main(int argc, char *argv[])
    {
            unsigned int bytes = 1024 * 1024;
            char *buf;

            /* allocate memory */
            buf = alloca(bytes);

            return 0;
    }
$ 4.2.36 27 526---> cat source.cocci
@@ expression E; @@

-alloca(E)
+malloc(E)
$ 4.2.36 28 527---> spatch --sp-file source.cocci source.c
init_defs_builtins: /usr/share/coccinelle/standard.h
HANDLING: source.c
diff =
--- source.c
+++ /tmp/cocci-output-9888-dc7b02-source.c
@@ -7,7 +7,7 @@ main(int argc, char *argv[])
             char *buf;

             /* allocate memory */
-            buf = alloca(bytes);
+            buf = malloc(bytes);

             return 0;
     }
$ 4.2.36 29 528---> spatch --sp-file source.cocci source.c -o newsource.c
init_defs_builtins: /usr/share/coccinelle/standard.h
HANDLING: source.c
diff =
--- source.c
+++ /tmp/cocci-output-9896-231c5d-source.c
@@ -7,7 +7,7 @@ main(int argc, char *argv[])
             char *buf;

             /* allocate memory */
-            buf = alloca(bytes);
+            buf = malloc(bytes);

             return 0;
     }
$ 4.2.36 30 529--->

open( ) system call

commandline session

$ 4.2.36 50 548---> cat test-open.c
#include 
#include 
#include 

main()
{
int fd;
fd = open( "text" , O_CREAT);
}
$ 4.2.36 51 549---> gcc test-open.c
$ 4.2.36 52 550---> ./a.out
$ 4.2.36 53 551---> ls
a.out  test-open.c  text
$ 4.2.36 54 552---> cat text
cat: text: Permission denied
$ 4.2.36 55 553---> ls -l  text
---S--s--T 1 jeffrin jeffrin 0 Sep  9 20:56 text
$ 4.2.36 56 554---> sudo cat text
[sudo] password for jeffrin:
$ 4.2.36 57 555---> umask -S
u=rwx,g=rx,o=rx
$ 4.2.36 58 556---> vi test-open.c
$ 4.2.36 59 557---> gcc test-open.c
$ 4.2.36 60 558---> ./a.out
$ 4.2.36 61 559---> ls -l  text
---S--s--T 1 jeffrin jeffrin 0 Sep  9 20:56 text
$ 4.2.36 62 560--->

universality of I/O

commandline session

$ 4.2.36 6 504---> sudo cp yt-chanrip /dev/tty43
[sudo] password for jeffrin:
$ 4.2.36 7 505---> tail -f /var/log/syslog
tail: cannot open `/var/log/syslog' for reading: Permission denied
$ 4.2.36 8 506---> sudo tail -f /var/log/syslog
Jan  5 21:04:54 debian -- MARK --
Jan  5 21:09:01 debian /USR/SBIN/CRON[4789]: (root) CMD (  [ -x /usr/lib/php5/maxlifetime ] && [ -d /var/lib/php5 ] && find /var/lib/php5/ -depth -mindepth 1 -maxdepth 1 -type f -cmin +$(/usr/lib/php5/maxlifetime) ! -execdir fuser -s {} 2>/dev/null ; -delete)
Jan  5 21:10:40 debian dbus[988]: [system] Activating service name='org.freedesktop.PackageKit' (using servicehelper)
Jan  5 21:10:40 debian dbus[988]: [system] Successfully activated service 'org.freedesktop.PackageKit'
Jan  5 21:16:48 debian dbus[988]: [system] Activating service name='org.freedesktop.PackageKit' (using servicehelper)
Jan  5 21:16:49 debian dbus[988]: [system] Successfully activated service 'org.freedesktop.PackageKit'
Jan  5 21:17:01 debian /USR/SBIN/CRON[4854]: (root) CMD (   cd / && run-parts --report /etc/cron.hourly)
Jan  5 21:35:39 debian kernel: Kernel logging (proc) stopped.
Jan  5 21:35:39 debian kernel: Kernel log daemon terminating.
Jan  5 21:35:41 debian exiting on signal 15

^C$ 4.2.36 9 507---> cat /dev/tty43
cat: /dev/tty43: Permission denied
$ 4.2.36 10 508---> sudo cat /dev/tty43
^Z
[1]+  Stopped                 sudo cat /dev/tty43
$ 4.2.36 11 509---> cat /dev/tty43
cat: /dev/tty43: Permission denied
$ 4.2.36 12 510---> sudo cat /dev/tty43
^C$ 4.2.36 13 511---sudo cp yt-chanrip /dev/tty43
$ 4.2.36 14 512---> fg 1
sudo cat /dev/tty43
^C$ 4.2.36 15 513---> cat /dev/tty1
tty1   tty10  tty11  tty12  tty13  tty14  tty15  tty16  tty17  tty18  tty19
$ 4.2.36 15 513---> cat /dev/tty1


$ 4.2.36 15 513---> cp /dev/tty1  uio.txt
cp: cannot open `/dev/tty1' for reading: Permission denied
$ 4.2.36 16 514---> sudo cp /dev/tty1  uio.txt
^C$ 4.2.36 17 515---> sudo cp /dev/pts/2  uio.txt
2
$ 4.2.36 17 515---> sudo cp /dev/pts/2  uio.txt

$ 4.2.36 17 515---> sudo cp /dev/pts/2  uio.txt
^C$ 4.2.36 18 516---> cat uio.txt
cat: uio.txt: Permission denied
$ 4.2.36 19 517---> sudo cat uio.txt
ssad$ 4.2.36 20 518---> cat uio.txt
cat: uio.txt: Permission denied
$ 4.2.36 21 519---> sudo less  uio.txt
$ 4.2.36 22 520---> sudo more  uio.txt
ssad
$ 4.2.36 23 521---> sudo less  uio.txt
$ 4.2.36 24 522--->