Friday, 18 September 2015

https://en.wikipedia.org/wiki/AFRINIC
 


African Network Information Center (AFRINIC)

AFRINIC has been allocated the IPv4 address blocks 41.0.0.0/8, 102.0.0.0/8, 105.0.0.0/8 and 197.0.0.0/8 and IPv6 blocks 2c00::/12 and 2001:4200::/23. AFRINIC also administers the address space for 196.0.0.0/8 and 154.0.0.0/8.[3]

 

Tuesday, 15 September 2015

$ who
pi@raspberrypi ~ $ who
pi       pts/0        2015-09-15 02:46 (192.168.1.13)

Information: List username(s) that logged into rpi.

$ date
 pi@raspberrypi ~ $ date
Tue Sep 15 04:59:33 UTC 2015

Information:

$ who am i
pi@raspberrypi ~ $ who am i
pi       pts/0        2015-09-15 02:46 (192.168.1.13)

Information:

$ date; who
pi@raspberrypi ~ $ date; who
Tue Sep 15 05:02:55 UTC 2015
pi       pts/0        2015-09-15 02:46 (192.168.1.13)

Information:
- date executed first; this is a compound (composed of two or more parts) command.
- dont forget the semi-colon to seperate commands

$ uptime
pi@raspberrypi ~ $ uptime
 05:32:33 up 13:49,  1 user,  load average: 0.00, 0.01, 0.05

Information:
- Show/tell how long the system has been up. In this example: 5 hours, 32 minutes, 33 seconds.

$ man

Information: command should you use to access the online help for a utility. Commands = utility.

$ ls

Example:
pi@raspberrypi ~ $ ls
add.sh     Desktop        helloworld    python_games    test.py
aloha.txt  Documents      helloworld.c  python.py.save  test.pyc
array.c    helloserver.c  learnc        Scratch         world.sh


$ ls -a

Information: list files and directories include hidden file.

Example:
pi@raspberrypi ~ $ ls -a
.              .bashrc          .gvfs          python_games    .vnc
..             .cache           helloserver.c  python.py.save  world.sh
add.sh         .config          helloworld     .scratch        .Xauthority
aloha.txt      .dbus            helloworld.c   Scratch         .xsession-errors
array.c        Desktop          .idlerc        test.py
.asoundrc      Documents        learnc         test.pyc
.bash_history  .fontconfig      .local         .themes
.bash_logout   .gstreamer-0.10  .profile       .thumbnails


$ ls -F
pi@raspberrypi ~ $ ls -F
add.sh*    Desktop/       helloworld*    python_games/   test.py*
aloha.txt  Documents/     helloworld.c*  python.py.save  test.pyc
array.c    helloserver.c  learnc/        Scratch/        world.sh*

$ ls -1

Information: 
Example:
pi@raspberrypi ~ $ ls -1
add.sh
aloha.txt
array.c
Desktop
Documents
helloserver.c
helloworld
helloworld.c
learnc
python_games
python.py.save
Scratch
test.py
test.pyc
world.sh

$ cat
To view the content of a file
Example:
pi@raspberrypi ~ $ cat helloworld.c
#include <stdio.h>

int main()
{
        printf("Hello, World!");
        return 0;
}

$ cat -n 
$ cat -n helloworld.c

To view the content of a file with numbers the output lines
Example:
pi@raspberrypi ~ $ cat -n helloworld.c
     1  #include <stdio.h>
     2
     3  int main()
     4  {
     5          printf("Hello, World!");
     6          return 0;
     7  }

$

Monday, 14 September 2015

execute
1.
2.

Creating a script:
1. Sha bang followed location of the shell interpreter location
2.
3. Name the script with like example.sh


Finding the location:
1. ps | grep $$
2. which bash 



Cisco logging

Fact:
0. Logging message are error messages of software or hardware.
1. Internal buffer logging mechanism enabled by default.
2. Syslog isn't enabled by default
3. Before configure logging, configure router is correct date, time and timezone.
4. To configure syslog, you must configure syslog-client within the router or built-in client.
5. Informational level displays reload request and low level stack process
6. Debug level displays
7. Notice level displays interface up or down transitions and system restart message


Facility = location

Recipes:
1. Enable syslog
Router#configure terminal
Router(config)#logging buffered informational

2. Set logging target remote log
Router#configure terminal
Router(config)# logging 172.25.1.1
Router(config)# end
Router#

3.  Changing the default log facility
Router#configure terminal
Router(config)# logging host 172.25.1.1
Router(config)# logging facility local6
Router(config)# end
Router#
By default, router will forward all syslog messages to the server's local7 log facility.

4. Restricting what log messages sent
Router# configure terminal
Router(config)# logging host 172.25.1.1
Router(config)# logging trap notifications
Router(config)# end

5. Rate limiting number of packets sent to syslog traffic
Router# configure terminal
Router(config)# logging host 172.25.1.1
Router(config)# logging rate-limit 30 except warning
Router(config)# end
Router#

http://www.wikihow.com/Find-The-Most-Searched-Keywords

Sunday, 13 September 2015

target:
1. Mark Things that discoverd this day
2. Thinkering yourself
3. Rich word to get rich life
4. When you questioning you get the answer
a > b + c
a = b + c + d
b ... d