grep -nr yourString /directory
result:
./fileA:10:. yourString
./fileB:11:. yourString
./fileC:13:. yourString
6 Jul
grep -nr yourString /directory
result:
./fileA:10:. yourString
./fileB:11:. yourString
./fileC:13:. yourString
13 Jun
Understanding the Login Shell Process
When you log in to the Linux system, the bash shell starts as a login shell. The login shell typically looks for five different startup files to process commands from:
1. /etc/profile
→The /etc/profile file is the main default startup file for the bash shell. Whenever you log in to the Linux system, bash executes the commands in the /etc/profile startup first.
2. $HOME/.bash_profile
3. $HOME/.bashrc
→The .bashrc file does two things. First, it checks for a common bashrc file in the /etc directory. Second, it provides a place for the user to enter personal command aliases
4. $HOME/.bash_login
5. $HOME/.profile
Source:
Linux Command Line and Shell Scripting Bible, Third Edition. (Book)
13 May
/bin/bash^M: bad interpreter: No such file or directory /bin/bash^M: bad interpreter: そのようなファイルやディレクトリはありません
Since the new line code had been saved in the \ r \ n, there is a need to fix in the Linux \ n. This is because the new line code had been saved in the \ r \ n on Windows environment. In order to fix the problem, we need to convert the \r\n to \n on Linux environment. To do this, we may use the below command:
$ sed -i 's/\r//' [shell script fileName]
By using the command cat -e, we can see that there is additional \ r at the newline code.
$ cat -e hello.sh #!/bin/bash^M$ echo "hello,world"^M$
This remains to run an error
$ ./hello.sh -bash: ./hello.sh: /bin/bash^M: bad interpreter: No such file or directory
Convert line feed code by using sed command
$ sed -i 's/\r//' hello.sh
once again check with cat -e
$ cat -e hello.sh #!/bin/bash$ echo "hello,world"$
Then, you are done!
$ ./hello.sh hello,world
8 Apr
★AIX compression with TAR, COMPRESS, GZIP, ZCAT
tar
tar in AIX by default does not support compression. You will need to incorporate with gzip command to have it
tar and compress at the same time.
$ tar cvf test.tar test # pure tar only $ tar cvf - test | gzip > test.tar.gz # tar and compress together
gzip / gunzip
$ gunzip -c test.tar.gz | tar tvf - # list compress files $ gunzip -c test.tar.gz | tar xvf - # decompress files
★nmon command
nmon -fT -s DATAinterval(unit in seconds) -c NUMBERofExecutions nmon -fT -s 1 -c 10800
→ Data will be recorded every 1 seconds
→ nmon data will be recorded : 1sec x 10800times = 3hours
★tcpdump
#Write an output file of tcpdump result
tcpdump -i en20 -w dumpfilename.out tcpdump -w dumpfile
#Read the result of tcpdump
tcpdump -r dumpfilename.out or tcpdump -r dumpfilename.out > dumpfilename.out.result more dumpfilename.out.result
★Check AIX Network Status
Network Interface
OVERVIEW and PROCEDURE
The task that is described in this procedure is performed in the AIX terminal window. If the terminal window
is not open at this time, you may do so by using the instructions in Hardware Management Console Overview.
After the terminal window is open, simply type
netstat -r
Where netstat = network status
-r = route
The primary information to check is located in the first entry in the top-left, “default”, and then the column
to the far right titled “If”. This column tells you what interface is being used. For instance, “en0”.
Secondarily, you may run an additional command to
entstat -dt en0
Where entstat = network settings
-dt = display all statistics
en0 = The interface from the If column
As a result of this command, the information that you should check is as follows:
Link Status : up Tells you that the cable is attached and is connected to a switch. In other words, the cable
from the system to the network is functional. This is a good thing!
NOTE: If the status is down (Link Status : down), there is a problem with the cable, or the switch, or the
port.
Media Speed Selected Should read “100 Mbps Full duplex”
Exception: If the machine has a gigabit card, it will read “Autonegotiate”
Media Speed Running Should read “100 Mbps Full duplex”
IF your system has a NIC / NIB (network interface backup) as en20, you may try the below command to check the
status of each primary and secondary network condition.
entstat -dt en20 | egrep “(Link Status|Media Speed)”
command result (sample):
Link Status: Up
Media Speed Selected : Autonegotiation
Media Speed Running : 1000 Mbps Full Duplex
Link Status: Up
Media Speed Selected : Autonegotiation
Media Speed Running : 1000 Mbps Full Duplex
25 Feb
Nah, berikut ini akan coba dijelaskan mengenai cara akses yang ditempuh untuk menuju Balai Indonesia SRIT. Dari Stasiun Meguro Anda dapat menggunakan bus. Naiklah bus dengan nomor-nomor yang tertera di bawah ini dari perhentian bus West Exit Stasiun JR Meguro. Turunlah di perhentian bus Motokeibajomae (元競馬場前).
Setelah turun di perhentian bus Motokeibajomae, seberangilah jalan besar (Meguro Dori) pada zebra crossterdekat kemudian belok ke kanan. Pada belokan ketiga beloklah ke kiri dan berjalan lurus sampai ke ujung gang kemudian beloklah ke kiri. Anda akan dapat melihat gerbang Balai Indonesia (SRIT) di ujung gang tersebut.
Anda dapat juga berjalan kaki dari Stasiun Meguro ke Balai Indonesia (SRIT). Perjalanan kaki membutuhkan waktu sekitar 17 menit (lihat peta di bawah).
17 Apr
Dzulfahmi, Naoya Ohta
“Performance Evaluation of Feature Descriptors for Application in Outdoor-scene Visual Navigation“
This paper has been presented in Master final defense, Gunma University in February 21st 2013.
The paper has also been accepted for an academic publication in the Asian Conference on Pattern Recognition 2013 (in conjunction with IAPR–International Association of Pattern Recognition), Okinawa, Japan.
Available online by IEEE Xplore Digital Library :
http://ieeexplore.ieee.org/xpl/articleDetails.jsp?arnumber=6778455
* Authors: Dzulfahmi, Naoya Ohta
* Title of publication: Performance Evaluation of Image Feature Detectors & Descriptors for Outdoor-scene Visual Navigation
Book, magazine or journal: 2nd IAPR Asian Conference on Pattern Recognition (ACPR) 2013, p. 872 – 876
* Publisher: IEEE Xplore
* Year of publication: 2013
ISBN/ISSN: 14197968
Please refer to the below presentation for the topic of my paper.
Oral Presentation at Master final defense.
11 Feb
3. Produk rumah tangga yang serba guna
dilombakan.
Tahap ke-3 (Tahap Grand-final : Presentasi di Jepang (dalam konfirmasi))
26 Oct
http://instagram.com/p/f4Qux1PxWW/
After a tough screening test from the IBM Japan Training Department last week, finally i passed the General Course for System Engineer in IBM. (Alhamdulillah!!)
*the picture was taken at Karuizawa station, Japan.
Recent Comments