Saturday, August 27, 2011

Thursday, August 18, 2011

ssh auto login script


#!/usr/bin/expect -f
# Expect script to supply root/admin password for remote ssh server 
# and execute command.
# This script needs three argument to(s) connect to remote server:
# password = Password of remote UNIX server, for root user.
# ipaddr = IP Addreess of remote UNIX server, no hostname
# scriptname = Path to remote script which will execute on remote server
# For example:
#  ./sshlogin.exp password 192.168.1.11 who 
# ------------------------------------------------------------------------
# Copyright (c) 2004 nixCraft project
# This script is licensed under GNU GPL version 2.0 or above
# -------------------------------------------------------------------------
# This script is part of nixCraft shell script collection (NSSC)
# Visit http://bash.cyberciti.biz/ for more information.
# ----------------------------------------------------------------------
# set Variables
set password [lrange $argv 0 0] 
set ipaddr [lrange $argv 1 1]   
set username [lrange $argv 2 2] 
set timeout -1   
# now connect to remote UNIX box (ipaddr) with given script to execute
spawn ssh $username@$ipaddr
match_max 100000
# Look for passwod prompt
expect "*?assword:*"
# Send password aka $password 
send -- "$password\r"
# send blank line (\r) to make sure we get back to gui
send -- "\r"
expect eof


Ref: http://bash.cyberciti.biz/security/expect-ssh-login-script/

Wednesday, August 17, 2011

sshd in cygwin

Following commands should be executed with root privilege.

ssh-host-config -y 
- In this command, it will ask the user name and password. The user name will be used for running the service.

cygrunsrv -S sshd 
- With this command, it will start the sshd. 

cygrunsrv -E sshd 
- With this command, it will end the sshd

cygrunsrv -R sshd 
- With this command, it will remove the sshd. In this case, it is necessary to re-run ssh-host-config again.

You may want to change the port ssh is using. In this case, you need to edit '/etc/sshd_config.' Replace the old port number (typically it is 22) with new one. Original configuration in that file would be the following:

Port 22

If you want to add the port for exceptions in your firewall, you may want to run the following command.

netsh firewall add portopening TCP #port OPRule_#port ENABLE

where #port is the port number you want to use.

For a newer version of the Windows firewall (probably after Windows 10), the following command can be used ('netsh firewall' is deprecated).

netsh advfirewall firewall add rule name="OPRule_#port" dir=in action=allow protocol=TCP localport=#port

Remove sshd from cygwin

1. Stop and remove sshd service.

cygrunsrv -S sshd 
cygrunsrv -R sshd

2. Remove any related user account information in /etc/passwd. Specifically, remove sshd and cyg_server account information.

3. Remove any related user account.

net user sshd /delete
net user cyg_server /delete

Sunday, August 14, 2011

Friday, August 12, 2011

Octave in Windows

Cygwin Octave has a problem with its connection with gnuplot, since Cygwin has a problem with its pipe system. Some people reported that some versions of cygwin is working. I tested with Windows 7 x64 with cygwin 1.7.9, it didn't work. I tested cygwin1-20100301.dll and cygwin1-20110803.dll, they didn't work either. Especially, 20100301 is version 1.7.8.


Octave Window version has a problem with oct2mat. When it is installed with oct2mat in Octave Forge, Octave didn't work gnuplot. So, it is better to install it with Octave Forge unless it is required.


http://octave.1599824.n4.nabble.com/Plot-window-not-updating-td2172704.html
http://wiki.octave.org/wiki.pl?OctaveForWindows

Wednesday, August 10, 2011

2011년 8월 10일 고배당주 중 저점 부근에 있는 종목들

1. KT
- 2011년 배당 2,410원
- 지난 3년간 2008년 금융위기를 포함하여 최저가 27,350원
- 35,000원 밑으로 거의 내려가지 않음


2. 대신증권
- 2011년 배당 보통주 750원 우선주 800원
- 지난 3년간 2008년 금융위기를 포함하여 최저각 9,740원
- 13,000원 밑으로 거의 내려가지 않음


3. 부국증권
- 2011년 배당 보통주 1,000원 우선주 1,050원
- 지난 3년간 2008년 금융위기를 포함하여 최저가 11,500원
- 15,000원 밑으로 거의 내려가지 않음


4. BS금융지주
- 2011년 상장
- 부산은행, BS투자증권, BS캐피탈, BS신용정보 등을 보유한 지주회사
- 지주사 전환후 250원의 결산 배당
- 배당성향이 25%이상일 경우 주당 500원 이상의 배당의 기대됨
http://economy.hankooki.com/lpage/stock/201105/e2011051814401592480.htm



5. 부산가스
- 2011년 배당 1,000원
- 지난 3년간 18,000원 밑으로 거의 내려가지 않음
- 지난 3년간 2008년 금융위기 포함하여 최저가 13,700원


6.진로발효
- 2011년 배당 1,000원
- 지난 3년간 11,500원 밑으로 내려간 적 거의 없음
- 2008년 금융위기 때 최저가 9,750원


7. 진로
- 국내 소주시장 1위 업체
- 2011년 현금 배당 보통주 1,500원 우선주 1,550원
- 지난 3년간 최저가 현재 28,350원


또 다른 고배당 관심 종목은 다음과 같다.
http://cn.moneta.co.kr/Service/stock/ShellView.asp?ArticleID=2011081109053400896&LinkID=263&NewsSetID=2141&StockCode=035250&codeName=%B0%AD%BF%F8%B7%A3%B5%E5&wlog_pip=news

Wednesday, August 3, 2011

HYNIX - Memory - 4 GB : 2 x 2 GB - SODIMM 204-pin - DDR3 - 1066 MHz / PC3-8500 - CL7 - 1.5 V - unbuffered - non-ECC



I'm selling 4GB: 2x2GB SODIMM memory which just got out of 2010 Macbook pro. Those have been working great so far. I am sure you can install these memories in your 2010 Macbook pro or any compatible laptops.

HYNIX- Memory - 4 GB : 2 x 2 GB - SODIMM 204-pin - DDR3 - 1066 MHz / PC3-8500 - CL7 - 1.5 V - unbuffered - non-ECC

Manufacturer Part #HMT125S6BFR8C-G7

Technical Specs
ManufacturerHynix
Manufacturer Part No.HMT125S6BFR8C-G7
Memory TypeSODIMM
Capacity2GB
Pins204 Pin
Bus TypePC-8500
Cycle Time1.875ns
CasCL7
Data Transfer Rate1066Mhz
Memory Clock133Mhz
Voltage1.5
ref: http://www.memory4less.com/m4l_itemdetail.aspx?itemId=1442676296&rid=fd_13_2_23_650

SAMSUNG - Memory - 2 GB : 2 x 1 GB - SODIMM 204-pin - DDR3 - 1066 MHz / PC3-8500 - CL7 - 1.5 V - unbuffered - non-ECC





I'm selling 2x1GB SODIMM memory which just got out of 2010 Macbook. Those have been working great so far. I am sure you can install these memories in your 2010 Macbook or any compatible laptops.


SAMSUNG - Memory - 2 GB : 2 x 1 GB - SODIMM 204-pin - DDR3 - 1066 MHz / PC3-8500 - CL7 - 1.5 V - unbuffered - non-ECC


Manufacturer Part #M471B2873EH1-CF8


Technical Specs
ManufacturerSamsung Electronics Co Ltd
Manufacturer Part No.M471B2873EH1-CF8
Memory TypeSODIMM
Capacity1GB
Pins204 Pin
Bus TypePC-8500
Cycle Time1.875ns
CasCL7
Data Transfer Rate1066Mhz
Memory Clock133Mhz
Voltage1.5
ref: http://www.memory4less.com/m4l_itemdetail.aspx?itemId=1442049120&rid=fd_13_2_9_535

Labels

1018 325i 3D 3D Printer 3M 500GB 7200RPM 747 850i A-GPS A-ha A8 ACCIDENT Actor Administrator Privilege ADOBE AdSense aGPS Airplane Algorithm Animation Ansur Antennagate API Apple AppleCare April Fool ARLuxrender Asian Assisted GPS ATT Audi Auto Bash Battleship BBC Bejeweled Bejeweled 3 Belkin Bike BITCOIN Black n Decker Blender Blog Blogspot Bluetooth BMW Bose Browser BTC Bump mapping Butter Butterface Butterfly C C++ C220 Calculator Calvin Klein CAR Cartoon Casshern CBR CBR600RR Cell CF CG Chair Chinese Chrome City Hunter CK Clie Clothe Coffee Coffee maker Color Comics Command Prompt Comment Commercial Compiler Computer Computer architecture Computer graphics Computer science Connex Content-Aware Fill Cowboy Bebop CRYPTOCURRENCY Cryptography CURL Cygwin Dabdate DB Decal Design Design thinking Development Digital Camera Digital communication Disaster Diskette Display Dog Dragon Ball Drama Drawing Driving Drying rack DSP Duck E-TRADE EA Earthquake Easter Egg eBay Economy Encryption ENGINEERING Error ESL etc ETH Ethernet expect F1 Face Fashion find Firefox Fish Flight Dynamics Floppy FON Food FREE Fun FWD G4 Game Gangsta Gangster GDAX GFX Ghost GIT Gizmo5 Golf Google Google Analytics Google Voice Gossip GPS Graphics Green Day GTI Gundam Gurren Lagann Hacking Hackintosh HARRP HASP SRM HCI HDD Headset Helicopter Helio High-tech History Hobby Honda Horror HP HTS Humor Hyundai iBook iBook G4 IKEA Illustration Image processing information theory Initial D Intel Internet Intro Iomega iPad iPhone iPhone 4 iPhone theme iPod iPod Video Iron IU Jailbreak Japan Java Jawbone Jeremy Jordan Jet Jetpack K12KB KAO Ken Block Ketchup Keynote KORBIT Korea Korean Kpop KRAKEN Kumho Kuwait Language Laptop LaserJet LCD Leaf Lego Lenovo Leopard Lexus LG Library Light saber Lightning Linear algebra Linux login LTC LTE Luxrender Lyric M30 MAC MacBook Macintosh Macross Macross 2 Macross Plus Magic MapReduce MARKET Matlab Mazinger Z MDRCBB Mechanical engineering Memory Microsoft Microwave Miniature Mio MLT Mobile Mobile Phone Moped Motorcycle Motorola Mouse Movie MP4 Music Music video Network Nike NODE. JS Nonlinear Optimization NORWAY Novel Octave Odaiba Olleh OpenGL Opening Orthodontics Oslo OSX Outlook Parody PBRT pctools Peanut Performance Perl Phone Photoshop PHP Picture Pidgin Plane Playstation Poem Polar bear Pop Portuguese post Pragma Prank Call Printer Program PROGRAMMING Protocol PS PUMA Push Push Push II PushPush PwnageTool PYTHON QuickTime R8 RAM RAZR RC Recording Report Robot Rock Rocket punch RSYNC Russel Crowe RWD Samsung Sandstorm Satellite Satellite Radio Scanner Science Score Script SD SDK Security sed Semantic Web Semiconductor SF Shell SHOW SIP Skype SK네트웍스 Slang Sleeve Soccer SOFTWARE Sonata Song Sounddock Soundgarden Space Spyshot SQL SSD ssh sshd Stanford bunny StarTrek Starwars Stethoscope Steve Jobs Sticker Stock Storage system Subaru Sun Super Deformed T-Shirt Taekwon V TBD Tease Technology Teeth Telecommunication Tennis tethering Textfree TH55 The Perfect Storm Theme TI-89 TIBURON Tires Titanium Tom Mabe Tooth Tooth Explorer Torrent Toshiba Toshiba Power Saver Toy TPS Transformer Tsunami TV TV shows Ubuntu UC Ultrabase UMN Universal Century Unix Unlock USB Used Video Virtuosity Vista Visual Studio VoIP VW WALLET Wallpaper Wanna Girl Wardriving Web 3.0 Wedding WiFi Wild Willy Windows Windows 7 Windows Vista Wireless WireShark WMV WOW WPS WRE54G X61 xargs XBOX XCode Yamato YF Youtube Z Gundam Zeliard Zuma 김간지 김현국 미국여자 방배추 뽀로로 위성 라디오 유희열 일본여자 조까를로스 주역 천자문 周易 天字文 德經 老子

Blog Archive