Mounting a hard disk image including partitions using Linux
ต้องการ Mount เฉพาะบาง Partition จาก Disk Image ที่สร้างด้วย > dd เพื่อมาใช้งาน
สร้าง Image ด้วย
# dd if=/dev/had of=hda.img 30544113+0 records in 30544113+0 records out
ก่อนอื่นหา Offset ของ Partition ที่ต้องการ Mount ก่อน
# parted hda.img GNU Parted 1.7.1 Using /data/rabbit/disk_image/test2 Welcome to GNU Parted! Type 'help' to view a list of commands. (parted) unit Unit? [compact]? B (parted) print Disk /data/rabbit/disk_image/test2: 10262568959B Sector size (logical/physical): 512B/512B Partition Table: msdos Number Start End Size Type File system Flags 1 32256B 106928639B 106896384B primary ext3 boot 2 106928640B 1184440319B 1077511680B primary linux-swap 3 1184440320B 10256924159B 9072483840B primary ext3 (parted) quit
สุดท้ายทำการ Mount ได้ด้วยคำสั่ง
#mount -o loop,ro,offset=32256 hda.img /mnt/rabbit
อ้างอิง http://www.andremiller.net/content/mounting-hard-disk-image-including-partitions-using-linux
Upgrade / NEW firmware ให้ Android Phone: SE Xperia x10 mini pro
ซื้อเครื่อง มือถือ Samsung Xperia X10 mini pro ผ่าน ebay มา กะว่าจะใช้หาความรู้เรื่อง Android หน่อย .. ก็ปรากฏว่าได้รู้ถึงความไม่รู้อีกมากมาย ดังนั้น หลังจากรู้แล้วจึงขอบันทึกไว้สักนิด เผื่อวันหนึ่งจะได้กลับมาทวนใหม่อีกครั้งหากต้องการรู้
เป้าหมายแรกคือ ลง ROM ใหม่ให้เป็น (การลง ROM, Kernel, หรือการ Root, Unlock Boot Loader, และการลง CWM – ClockWorkMod หรือ Xrecovery คือ การเพิ่มประสิทธิภาพของเครื่อง Android ทางหนึ่ง)
Linux force reboot/shutdown « Sameh M. Shaker’s Weblog
Forcing reboot
Linux is not Windows XP and if reboot fail you usually still connect by SSH and do something. This commands will show you how to remotely hard reboot machine. Hard reboot mean that shutdown scripts will not run and machine reboot immediately without syncing hard disk drives, shutdown applications etc, it’s more like hitting the reset button.
echo 1 > /proc/sys/kernel/sysrq
echo b > /proc/sysrq-trigger
This commands enable sysrq and after this calls fast reboot. If you want to force shutdown machine try this.
Force shutdown
echo 1 > /proc/sys/kernel/sysrq
echo o > /proc/sysrq-trigger
Pasted from
Make debian package from Source ด้วย checkinstall
เมื่อต้องการสร้าง DEB จาก Source tar.gz ที่ download มาแน่นอนว่าเริ่มต้นจาก
> ./configure
> make
แต่ก่อนจะ make install ให้ใช้
> sudo checkinstall
ก็จะได้ DEB พร้อมกับทำการ install ให้เสร็จสรรพ
แต่ บางครั้ง อาจต้อง
> sudo checkinstall sudo make install
การใช้งาน ProxyChains เพื่อ Re-direct TCP connections
ปัญหา Print Page – [solved] proxychains.
ต้องการใช้ ProxyChains เพื่อให้ Re-direct TCP connection ในบางโปรแกรม เช่น nmap แต่ก็เจอปัญหา
ProxyChains-3.1 (http://proxychains.sf.net) ERROR: ld.so: object 'libproxychains.so' from LD_PRELOAD cannot be preloaded: ignored.
ทำให้ต้องแก้ไขใน > /usr/bin/proxychains ตาม http://pastebin.com/nkMKKUKw ว่า
- export LD_PRELOAD=libproxychains.so
+ export LD_PRELOAD=/usr/lib/libproxychains.so
และที่สำคัฐคือ
/etc/proxychains.conf
- ให้ตั้ง proxy server ด้วย ip ไม่ใช่ url
- ให้ disable DNS
ps. สำหรับโปรแกรม Firefox, Chrome, ThunderBird, Putty ไม่จำเป็นต้องใช้ เพราะสามารถตั้งค่าได้ (ค่า Proxy) ภายในตัวโปรแกรมเองอยู่แล้ว
HipHop for PHP: Move Fast – Facebook Developers
HipHop for PHP isn’t technically a compiler itself. Rather it is a source code transformer. HipHop programmatically transforms your PHP source code into highly optimized C++ and then uses g++ to compile it.
คำศัพท์ในงานวิจัย Natural Language Processing
Dictionary:
Thesaurus:
Lexicon:
Word Stock:
Synset
Synonym Ring
Corpus
CACertificates – Mercurial
เจอปัญหาเวลา hg push คือ
warning: bitbucket.org certificate with fingerprint 81:2b:08:90:dc:d3:71:ee:e0:7c:b4:75:ce:9b:6c:48:94:56:a1:fe not verified (check hostfingerprints or web.cacerts config setting)
แค่ ใส่ บรรทัดด้านล่างนี้ใน .hg เท่านั้น
[web]
cacerts = /etc/ssl/certs/ca-certificates.crt
via CACertificates – Mercurial.
หรือ
http://tadabborat.tumblr.com/post/9502320721/mercurial-warning-bitbucket-org-certificate-with
XMind ไม่มี Menu ใน Ubuntu 11.04
หลังจากเปลี่ยนมาใช้ 11.04 (เดิม 10.04) เมนูพวก Eclipse Based ก็หาย .. มีทางแก้ดังนี้
Run XMind in Ubuntu 11.04, Natty Narwhale – XMind User Forum | Google Groups.
ต่อไปนี้ไม่ต้องง้อ Grave แล้ว..เฮ
จาก Grave accent – Wikipedia, the free encyclopedia. ต่อไปนี้ไม่ต้องง้อ Grave แล้ว !!
In the Bash shell, the `...` is deprecated in favour of $(...).[6] The same is true of Z shell.[7]