환경 구축 아카이브
[현 상자] 커널을 다시 구축
U-Boot에서 사용할 수있는 초대 玄 상자 (무인)의 2.6.25.20Linux 커널을 만듭니다.
우선 컴파일에 필요한 프로그램을 설치.
KURO-BOX:/usr/src# aptitude install patch KURO-BOX:/usr/src# aptitude install libncurses-dev KURO-BOX:/usr/src# aptitude install bzip2 KURO-BOX:/usr/src# aptitude install module-init-tools 다음 소스 다운로드하여 압축을 푼다.
KURO-BOX:/usr/src# wget http://www.genbako.com/kurobox-sources-2.6.25.patch KURO-BOX:/usr/src# wget http://www.genbako.com/kurobox-section-mismatch2625.patch KURO-BOX:/usr/src# wget http://www.kernel.org/pub/linux/kernel/v2.6/linux-2.6.25.20.tar.bz2 KURO-BOX:/usr/src# tar -jxpvf linux-2.6.25.20.tar.bz2 다음 패치를 맞춥니다.
KURO-BOX:/usr/src# cd linux-2.6.25.20 KURO-BOX:/usr/src/linux-2.6.25.20# patch -Np1 < ../kurobox-section-mismatch2625.patch KURO-BOX:/usr/src/linux-2.6.25.20# patch -Np1 < ../kurobox-sources-2.6.25.patch 그런 다음 이전 준비를한다.
KURO-BOX:/usr/src/linux-2.6.25.20# export ARCH=ppc KURO-BOX:/usr/src/linux-2.6.25.20# cp config_kurobox .config KURO-BOX:/usr/src/linux-2.6.25.20# make oldconfig 여기서 중요한 커널을 설정한다.
KURO-BOX:/usr/src/linux-2.6.25.20# make menuconfig Networking > Networking options <*> Packet socket [*] Packet socket: mmapped IO <*> Unix domain sockets < > Transformation user configuration interface [ ] Transformation sub policy support (EXPERIMENTAL) [ ] Transformation migrate database (EXPERIMENTAL) [ ] Transformation statistics (EXPERIMENTAL) <M> PF_KEY sockets [ ] PF_KEY MIGRATE (EXPERIMENTAL) (NEW) [*] TCP/IP networking [*] IP: multicasting [*] IP: advanced router Choose IP: FIB lookup algorithm (choose FIB_HASH if unsurx x [*] IP: policy routing [ ] IP: equal cost multipath (NEW) [ ] IP: verbose route monitoring (NEW) [ ] IP: kernel level autoconfiguration <M> IP: tunneling <M> IP: GRE tunnels over IP [*] IP: broadcast GRE over IP [*] IP: multicast routing [*] IP: PIM-SM version 1 support [*] IP: PIM-SM version 2 support [ ] IP: ARP daemon support (EXPERIMENTAL) [ ] IP: TCP syncookie support (disabled per default) <M> IP: AH transformation <M> IP: ESP transformation <M> IP: IPComp transformation <*> IP: IPsec transport mode <*> IP: IPsec tunnel mode <*> IP: IPsec BEET mode < > Large Receive Offload (ipv4/tcp) <*> INET: socket monitoring interface [ ] TCP: advanced congestion control ---> [*] TCP: MD5 Signature Option support (RFC2385) (EXPERIMENTAL) < > IP virtual server support (EXPERIMENTAL) (NEW) ---> < > The IPv6 protocol [ ] Security Marking [*] Network packet filtering framework (Netfilter) ---> [*] Network packet filtering debugging [*] Advanced netfilter configuration (NEW) [*] Bridged IP/ARP packets filtering (NEW) Core Netfilter Configuration ---> <M> Netfilter NFQUEUE over NFNETLINK interface <M> Netfilter LOG over NFNETLINK interface <M> Netfilter connection tracking support -*- Connection tracking flow accounting -*- Connection mark tracking support [*] Connection tracking events <M> SCTP protocol connection tracking support (EXPERIMENTAL) <M> UDP-Lite protocol connection tracking support <M> Amanda backup protocol support <M> FTP protocol support <M> H.323 protocol support <M> IRC protocol support <M> NetBIOS name service protocol support <M> PPtP protocol support <M> SANE protocol support (EXPERIMENTAL) <M> SIP protocol support <M> TFTP protocol support <M> Connection tracking netlink interface {M} Netfilter Xtables support (required for ip_tables) <M> "CLASSIFY" target support <M> "CONNMARK" target support <M> "DSCP" and "TOS" target support <M> "MARK" target support <M> "NFQUEUE" target Support <M> "NFLOG" target support <M> "NOTRACK" target support -M- "RATEEST" target support <M> "TRACE" target support <M> "TCPMSS" target support <M> "TCPOPTSTRIP" target support (EXPERIMENTAL) <M> "comment" match support <M> "connbytes" per-connection counter match support <M> "connlimit" match support" <M> "connmark" connection mark match support <M> "conntrack" connection tracking match support <M> "dccp" protocol match support <M> "dscp" and "tos" match support <M> "esp" match support <M> "helper" match support <M> "iprange" address range match support <M> "length" match support <M> "limit" match support <M> "mac" address match support <M> "mark" match support <M> "owner" match support <M> IPsec "policy" match support <M> "multiport" Multiple port match support <M> "physdev" match support <M> "pkttype" packet type match support <M> "quota" match support <M> "rateest" match support <M> "realm" match support <M> "sctp" protocol match support (EXPERIMENTAL) <M> "state" match support <M> "statistic" match support <M> "string" match support <M> "tcpmss" match support <M> "time" match support <M> "u32" match support <M> "hashlimit" match support IP: Netfilter Configuration ---> <M> IPv4 connection tracking support (required for NAT) [*] proc/sysctl compatibility with old connection tracking (NEW) <M> IP Userspace queueing via NETLINK (OBSOLETE) <M> IP tables support (required for filtering/masq/NAT) <M> "recent" match support <M> "ecn" match support <M> "ah" match support <M> "ttl" match support <M> "addrtype" address type match support <M> Packet filtering <M> REJECT target support <M> LOG target support <M> ULOG target support <M> Full NAT <M> MASQUERADE target support <M> REDIRECT target support <M> NETMAP target support <M> Basic SNMP-ALG support <M> Packet mangling <M> ECN target support <M> TTL target support <M> CLUSTERIP target support (EXPERIMENTAL) <M> raw table support (required for NOTRACK/TRACE) <M> ARP tables support <M> ARP packet filtering <M> ARP payload mangling Bridge: Netfilter Configuration ---> <M> Ethernet Bridge tables (ebtables) support <M> ebt: broute table support <M> ebt: filter table support <M> ebt: nat table support <M> ebt: 802.3 filter support <M> ebt: among filter support <M> ebt: ARP filter support <M> ebt: IP filter support <M> ebt: limit match support <M> ebt: mark filter support <M> ebt: packet type filter support <M> ebt: STP filter support <M> ebt: 802.1Q VLAN filter support <M> ebt: arp reply target support <M> ebt: dnat target support <M> ebt: mark target support <M> ebt: redirect target support <M> ebt: snat target support <M> ebt: log support <M> ebt: ulog support (OBSOLETE) < > The DCCP Protocol (EXPERIMENTAL) ---> < > The SCTP Protocol (EXPERIMENTAL) ---> < > The TIPC Protocol (EXPERIMENTAL) ---> < > Asynchronous Transfer Mode (ATM) <M> 802.1d Ethernet Bridging <M> 802.1Q VLAN Support < > DECnet Support < > ANSI/IEEE 802.2 LLC type 2 Support < > The IPX protocol < > Appletalk protocol support < > CCITT X.25 Packet Layer (EXPERIMENTAL) < > LAPB Data Link Driver (EXPERIMENTAL) < > Acorn Econet/AUN protocols (EXPERIMENTAL) < > WAN router [ ] QoS and/or fair queueing ---> Network testing ---> Networking > Wireless {*} Improved wireless configuration API [*] nl80211 new netlink interface support (NEW) -*- Wireless extensions <M> Generic IEEE 802.11 Networking Stack (mac80211) Rate control algorithm selection ---> [ ] Enable packet alignment debugging (NEW) [ ] Enable debugging output (NEW) {M} Generic IEEE 802.11 Networking Stack (DEPRECATED) [ ] Enable full debugging output (NEW) -M- IEEE 802.11 WEP encryption (802.1x) < > IEEE 802.11i CCMP support (NEW) < > IEEE 802.11i TKIP encryption (NEW) < > Software MAC add-on to the IEEE 802.11 networking stack (NEW) Device Drivers > Networking device support [ ] Netdevice multiple hardware queue support <M> Dummy net driver support < > Bonding driver support < > MAC-VLAN support (EXPERIMENTAL) < > EQL (serial line load balancing) support <M> Universal TUN/TAP device driver support < > Virtual ethernet pair device < > ARCnet support ---> < > PHY Device support and infrastructure ---> [*] Ethernet (10 or 100Mbit) ---> [*] Ethernet (1000 Mbit) ---> [ ] Ethernet (10000 Mbit) ---> [ ] Token Ring driver support ---> Wireless LAN ---> [ ] Wireless LAN (pre-802.11) [*] Wireless LAN (IEEE 802.11) < > Intel PRO/Wireless 2100 Network Connection (NEW) < > Intel PRO/Wireless 2200BG and 2915ABG Network Connection (NEW) < > Marvell 8xxx Libertas WLAN driver support (NEW) < > Cisco/Aironet 34X/35X/4500/4800 ISA and PCI cards (NEW) <M> Hermes chipset 802.11b support (Orinoco/Prism2/Symbol) < > Hermes in PLX9052 based PCI adaptor support (Netgear MA30 < > Hermes in TMD7160 based PCI adaptor support (NEW) < > Nortel emobility PCI adaptor support (NEW) < > Prism 2.5 PCI 802.11b adaptor support (NEW) < > Atmel at76c50x chipset 802.11b support (NEW) < > Intersil Prism GT/Duette/Indigo PCI/Cardbus (NEW) <M> USB ZD1201 based Wireless device support < > Wireless RNDIS USB support (NEW) < > Realtek 8180/8185 PCI support (NEW) <M> Realtek 8187 USB support < > ADMtek ADM8211 support (NEW) < > Softmac Prism54 support (NEW) < > Atheros 5xxx wireless cards support (NEW) < > Intel Wireless WiFi 4965AGN (NEW) < > Intel PRO/Wireless 3945ABG/BG Network Connection (NEW) <M> IEEE 802.11 for Host AP (Prism2/2.5/3 and WEP/TKIP/CCMP) [*] Support downloading firmware images with Host AP driver [*] Support for non-volatile firmware download < > Host AP driver for Prism2/2.5/3 in PLX9052 PCI adaptors < > Host AP driver for Prism2.5 PCI adaptors (NEW) < > Broadcom 43xx wireless support (mac80211 stack) (NEW) < > Broadcom 43xx-legacy wireless support (mac80211 stack) (NEW) <M> ZyDAS ZD1211/ZD1211B USB-wireless support [*] ZyDAS ZD1211 debugging < > Ralink driver support (NEW) USB Network Adapters ---> < > USB CATC NetMate-based Ethernet device support (EXPERIMENTAL) < > USB KLSI KL5USB101-based ethernet device support < > USB Pegasus/Pegasus-II based ethernet device support <M> USB RTL8150 based ethernet device support (EXPERIMENTAL) < > Multi-purpose USB Networking Framework [ ] Wan interfaces support ---> [ ] FDDI driver support [ ] HIPPI driver support (EXPERIMENTAL) < > PPP (point-to-point protocol) support < > SLIP (serial line) support [ ] Fibre Channel driver support < > Network console logging support (EXPERIMENTAL) 우선, iptable, IPsec, 멀티 캐스트 IPIP / GRE 터널, Dummy 인터페이스, 브리지, 802.1Q VLAN과 USB 무선 LAN의 일부를 사용하여 설정을 저장합니다.
그리고 결국 컴파일. 여기서 uImage를 생성합니다.
KURO-BOX:/usr/src/linux-2.6.25.20# make uImage scripts/kconfig/conf -s arch/ppc/Kconfig CHK include/linux/version.h UPD include/linux/version.h CHK include/linux/utsrelease.h UPD include/linux/utsrelease.h SYMLINK include/asm -> include/asm-ppc CC arch/ppc/kernel/asm-offsets.s ~省略~ LD .tmp_vmlinux2 KSYM .tmp_kallsyms2.S AS .tmp_kallsyms2.o LD vmlinux SYSMAP System.map SYSMAP .tmp_System.map OBJCOPY arch/ppc/boot/images/vmlinux.bin GZIP arch/ppc/boot/images/vmlinux.gz UIMAGE arch/ppc/boot/images/uImage Image Name: Linux-2.6.25.20-kurobox Created: Sat Jul 2 21:40:24 2011 Image Type: PowerPC Linux Kernel Image (gzip compressed) Data Size: 1460604 Bytes = 1426.37 kB = 1.39 MB Load Address: 0x00000000 Entry Point: 0x00000000 Image: arch/ppc/boot/images/uImage is ready 무사히 uImage가 만들었으므로 계속해서 모듈을 만들고 설치
KURO-BOX:/usr/src/linux-2.6.25.20# make modules KURO-BOX:/usr/src/linux-2.6.25.20# make modules_install 작성 uImage를 저장하기 위해 기존의 백업
KURO-BOX:/usr/src/linux-2.6.25.20# cd /boot KURO-BOX:/boot# ls -la drwxr-xr-x 3 root root 4096 2011-06-26 22:35 . drwxr-xr-x 21 root root 4096 2011-04-10 05:23 .. -rw-r--r-- 1 tmp-kun tmp-kun 31064 2008-05-04 22:18 .config -rw-r--r-- 1 root root 718574 2011-06-26 18:20 System.map -rw-r--r-- 1 root root 1465831 2011-06-26 22:01 uImage lrwxrwxrwx 1 tmp-kun tmp-kun 6 2011-04-10 05:25 vmlinux.UBoot -> uImage -rwxr-xr-x 1 tmp-kun tmp-kun 3063942 2008-05-04 22:18 vmlinux.bin KURO-BOX:/boot# mv System.map System.map.org KURO-BOX:/boot# mv uImage uImage.org 만든 uImage와 복사합니다.
KURO-BOX:/boot# cp -p /usr/src/linux-2.6.25.20/arch/ppc/boot/images/uImage /boot KURO-BOX:/boot# cp -p /usr/src/linux-2.6.25.20/System.map /boot 궁극적으로 이런 느낌
KURO-BOX:/boot# ls -la drwxr-xr-x 3 root root 4096 2011-06-26 22:35 . drwxr-xr-x 21 root root 4096 2011-04-10 05:23 .. -rw-r--r-- 1 tmp-kun tmp-kun 31064 2008-05-04 22:18 .config -rw-r--r-- 1 root root 718574 2011-06-26 18:20 System.map -rw-r--r-- 1 tmp-kun tmp-kun 694437 2008-05-04 22:18 System.map.org -rw-r--r-- 1 root root 1465831 2011-06-26 22:01 uImage -rw-r--r-- 1 tmp-kun tmp-kun 1432414 2008-05-04 22:18 uImage.org lrwxrwxrwx 1 tmp-kun tmp-kun 6 2011-04-10 05:25 vmlinux.UBoot -> uImage -rwxr-xr-x 1 tmp-kun tmp-kun 3063942 2008-05-04 22:18 vmlinux.bin 이제 다시 시작되면 시작 확인합니다.
KURO-BOX:~# uname -a Linux KURO-BOX 2.6.25.20-kurobox #3 Sun Jun 26 21:59:59 JST 2011 ppc GNU/Linux 커널 버전이 업데이 트되었는지 확인
[현 상자] mkimage 만들기
U-Boot에서 사용할 수있는 형태로 커널 컴파일하기 위해 mkimage를 컴파일
현재 玄 상자에는 U-Boot1.1.4가 들어 있기 때문에 1.1.4 소스로부터 작성한다.
먼저 소스를 다운로드하여 압축
KURO-BOX:~# cd /usr/src/ KURO-BOX:/usr/src# wget http://prdownloads.sourceforge.net/u-boot/u-boot-1.1.4.tar.bz2 KURO-BOX:/usr/src# tar -xjvf u-boot-1.1.4.tar.bz2 KURO-BOX:/usr/src# cd u-boot-1.1.4 다음 make 시에 $ TOPDIR를 참조하는 것 같기 때문에 현재 경로를 저장한다.
KURO-BOX:/usr/src/u-boot-1.1.4# export TOPDIR=`pwd` KURO-BOX:/usr/src/u-boot-1.1.4# echo $TOPDIR /usr/src/u-boot-1.1.4 이번 필요한 것은 mkimage 그래서 tools 디렉토리에서만 make한다.
KURO-BOX:/usr/src/u-boot-1.1.4# cd tools KURO-BOX:/usr/src/u-boot-1.1.4/tools# make mkimage ln -s ../common/environment.c environment.c ln -s ../lib_generic/crc32.c crc32.c gcc -M -Wall -pedantic -idirafter ../include -DTEXT_BASE= -DUSE_HOSTCC environment.c img2srec.c mkimage.c crc32.c envcrc.c gen_eth_addr.c bmp_logo.c > .depend environment.c:28:20: error: config.h: No such file or directory envcrc.c:32:20: error: config.h: No such file or directory gcc -g -Wall -pedantic -idirafter ../include -DTEXT_BASE= -DUSE_HOSTCC -O -c mkimage.c gcc -g -Wall -pedantic -idirafter ../include -DTEXT_BASE= -DUSE_HOSTCC -O -c crc32.c gcc -Wall -pedantic -idirafter ../include -DTEXT_BASE= -DUSE_HOSTCC -O -o mkimage mkimage.o crc32.o strip mkimage 오류가 나와 있지만이 mkimage에서 U-Boot 가능한 커널은 문제없이 만들어 시작할 수 있었다.
KURO-BOX:/usr/src/u-boot-1.1.4/tools# cp -p mkimage /usr/local/bin KURO-BOX:/usr/src/u-boot-1.1.4/tools# which mkimage /usr/local/bin/mkimage 만든 mkimage는 / usr / local / bin 등 path에있는 위치에 복사 완료.
[현 상자] GCC 설치
GCC를 설치했지만 3.4 계와 기본 (4.3 계)의 2 버전을 설치
KURO-BOX:~# aptitude install gcc gcc-3.4 설치가 끝나면 전환하도록 update-alternatives에서 설정 · · · 그렇다고는해도, 다음 명령으로 확인해 보면
KURO-BOX:~# update-alternatives --display gcc No alternatives for gcc. 없는 것. 다른 이름으로 존재하고있는지도와 다음 명령에서 설정할 수있는 모든 것을 설정 해 본다
KURO-BOX:~# update-alternatives --all 역시없는 것.
그래서 수동으로 추가 (그룹 이름은 "gcc"고했다.)
KURO-BOX:~# update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-3.4 34 --slave /usr/bin/cpp cpp /usr/bin/cpp-3.4 --slave /usr/bin/gcov gcov /usr/bin/gcov-3.4 KURO-BOX:~# update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-4.3 43 --slave /usr/bin/cpp cpp /usr/bin/cpp-4.3 --slave /usr/bin/gcov gcov /usr/bin/gcov-4.3 기본적으로 gcc-3.4를 사용하도록 설정
KURO-BOX:~# update-alternatives --config gcc There are 2 alternatives which provide `gcc'. Selection Alternative ----------------------------------------------- * 1 /usr/bin/gcc-3.4 + 2 /usr/bin/gcc-4.3 Press enter to keep the default[*], or type selection number: 1 Using '/usr/bin/gcc-3.4' to provide 'gcc'. [현 상자]玄상자를 초기화
초대 玄 상자 (무인)를 U-Boot화한 뒤, 방치하고 있었으므로 HDD을 포맷하고 다시 설치를 갔을 때의 메모.
- HDD 포맷 <br /> 이번에는 의도적으로 HDD를 제거하고 Windows7에서 파티션을 삭제했습니다.
포맷이 완료되면 현 상자에 다시 조립합니다. - nc에서 시작 현황 및 U-Boot 명령 모드로
Windows 컴퓨터에서 nc 을 준비하고玄상자와 크로스 케이블로 연결 (스트레이트 케이블과 후면 스위치 지원).
Windows PC 측의 IP 주소를 198.168.11.149로 설정하고 명령 프롬프트에서 nc 폴더로 이동하여 다음 명령을 실행 시작nc -v -v -n -u -s 192.168.11.149 -p 6666 192.168.11.150 6666이제 192.168.11.150를 조사하는 상태가되기 때문에, 현 상자를 시작하면 아래와 같이 나타납니다
U-Boot 1.1.4 LiSt 2.1.0 (Sep 21 2006 - 00:22:56) LinkStation / KuroBox CPU: MPC8245 Revision 1.4 at 196.608 MHz: 16 kB I-Cache 16 kB D-Cache DRAM: 64 MB FLASH: 4 MB ~省略~ Boot in 10 seconds ('s' to stop)...여기에서 s]를 입력하고 U-Boot의 명령 모드로 들어간다.
Boot in 7 seconds ('s' to stop)... s => - EM 모드로
=> run writeng Un-Protected 1 sectors Flash erase: first = 55 @ 0xfff70000 last = 55 @ 0xfff70000 Flash erase: Done Erased 1 sectors Copy to Flash... done => run emboot ## Booting image at ffc00000 ... ******* Product Information ******* [#k0621bb4] ---------------------------------- Product Name: KURO-BOX(IETSUNA) VER: 1.02 Date: 2004/4/16 11:46:41 ---------------------------------- Verifying checksum... OK Uncompressing kernel...done. Loading Ramdisk at 0x03C67000, end 0x03E6E647 ... OK Booting the kernel ~省略~이제 EM 모드에서 일어서있는 것이므로, 크로스 케이블을 분리하고 DHCP가 움직이고있는 LAN에 연결합니다.
- 파티션을 생성
HDD 전체 영역을 제거root@KURO-BOX:~# /sbin/mfdisk -e /dev/hda delete partition 1 delete partition 2 delete partition 3 delete partition 4 create partitions... deleate all partitions. The partition table has been altered! Syncing disks.이어 공간 확보 (제 1 공간 : 4GB, 제 2 영역 SWAP 용 : 256MB, 제 3 영역 : 나머지)
root@KURO-BOX:~# /sbin/mfdisk -c /dev/hda Command (m for help): n Command action e extended p primary partition (1-4) p Partition number (1-4): 1 First cylinder (1-15798, default 1): [enter] Using default value 1 Last cylinder or +size or +sizeM or +sizeK (1-15798, default 15798): +4000M Command (m for help): n Command action e extended p primary partition (1-4) p Partition number (1-4): 2 First cylinder (8128-15798, default 8128): [enter] Using default value 8128 Last cylinder or +size or +sizeM or +sizeK (8128-15798, default 15798): +256M Command (m for help): n Command action e extended p primary partition (1-4) p Partition number (1-4): 3 First cylinder (8649-15798, default 8649): [enter] Using default value 8649 Last cylinder or +size or +sizeM or +sizeK (8649-15798, default 15798): [enter] Using default value 15798 Command (m for help): t Partition number (1-4): 2 Hex code (type L to list codes): 82 Changed system type of partition 2 to 82 (Linux swap) Command (m for help): p Disk /dev/hda: 16 heads, 63 sectors, 15798 cylinders Units = cylinders of 1008 * 512 bytes Device Boot Start End Blocks Id System /dev/hda1 1 8127 4095976+ 83 Linux /dev/hda2 8128 8648 262584 82 Linux swap /dev/hda3 8649 15798 3603600 83 Linux Command (m for help): w The partition table has been altered! Syncing disks. - 작성 영역을 포맷 <br /> 우선은 제 1 영역 (LinuxOS)
root@KURO-BOX:~# /sbin/mke2fs -j /dev/hda1 mke2fs 1.22, 22-Jun-2001 for EXT2 FS 0.5b, 95/08/09 Filesystem label= OS type: Linux Block size=4096 (log=2) Fragment size=4096 (log=2) 512000 inodes, 1023994 blocks 51199 blocks (5.00%) reserved for the super user First data block=0 32 block groups 32768 blocks per group, 32768 fragments per group 16000 inodes per group Superblock backups stored on blocks: 32768, 98304, 163840, 229376, 294912, 819200, 884736 Writing inode tables: done Creating journal (8192 blocks): done Writing superblocks and filesystem accounting information: done This filesystem will be automatically checked every 21 mounts or 180 days, whichever comes first. Use tune2fs -c or -i to override.다음 제 2 영역 (Swap)
root@KURO-BOX:~# /sbin/mkswap /dev/hda2 Setting up swapspace version 1, size = 268881920 bytes마지막 제 3 영역 (Data)
root@KURO-BOX:~# /sbin/mke2fs -j -m 0 /dev/hda3 mke2fs 1.22, 22-Jun-2001 for EXT2 FS 0.5b, 95/08/09 Filesystem label= OS type: Linux Block size=4096 (log=2) Fragment size=4096 (log=2) 450688 inodes, 900900 blocks 0 blocks (0.00%) reserved for the super user First data block=0 28 block groups 32768 blocks per group, 32768 fragments per group 16096 inodes per group Superblock backups stored on blocks: 32768, 98304, 163840, 229376, 294912, 819200, 884736 Writing inode tables: done Creating journal (8192 blocks): done Writing superblocks and filesystem accounting information: done This filesystem will be automatically checked every 28 mounts or 180 days, whichever comes first. Use tune2fs -c or -i to override. - 만든 공간을 마운트
root@KURO-BOX:~# mount -t ext3 /dev/hda1 /mnt root@KURO-BOX:~# mount -t ext3 /dev/hda3 /mnt2 root@KURO-BOX:~# df -h Filesystem Size Used Available Use% Mounted on /dev/ram0 9.5M 5.0M 4.5M 53% / /dev/hda1 3.8G 32.1M 3.6G 1% /mnt /dev/hda3 3.4G 32.1M 3.4G 1% /mnt2 - OS 데이터 전송
FTP (FileZilla 등)에서 다음 파일을 / mnt2 (/ dev/hda3)에 u-boot 폴더를 만들고 다음의 3 개의 저장- Revulo 's Laboratory보다 debian5.0 lenny의 압축 파일 ( debian-lenny-kuroBOX-20090317.tgz )
- 커널 이미지 ( kernelimage-2.6.20-kuroBOX-uImage.tgz )
- 커널 모듈 ( modules-2.6.20-kuroBOX.tgz )
전송이 완료되면 확인 해 본다.
root@KURO-BOX:~# ls /mnt2/u-boot debian-lenny-kuroBOX-20090317.tgz kernelimage-2.6.20-kuroBOX-uImage.tgz modules-2.6.20-kuroBOX.tgz - OS 설치
Debian5.0 (lenny)를 / dev/hda1 (/ mnt)로 확장root@KURO-BOX:~# cd /mnt root@KURO-BOX:~# pwd /mnt root@KURO-BOX:~# tar xvzf /mnt2/u-boot/debian-lenny-kuroBOX-20090317.tgz ~省略~/ dev/hda1 (/ mnt) 확인
root@KURO-BOX:~# ls /mnt bin home mnt sbin tmp boot lib opt selinux usr dev lost+found proc srv var etc media root sys커널 이미지 (2.6.20)을 / dev/hda1/boot (/ mnt / boot)로 확장
root@KURO-BOX:~# tar xvfz /mnt2/u-boot/kernelimage-2.6.20-kuroBOX-uImage.tgz .config System.map vmlinux.UBoot uImage/ boot의 내용을 확인
root@KURO-BOX:~# ls /mnt/boot System.map uImage vmlinux.UBoot커널 모듈 (2.6.20)을 / dev/hda1/lib/modules (/ mnt / lib / modules)로 확장
root@KURO-BOX:~# cd /mnt/lib/modules root@KURO-BOX:~# pwd /mnt/lib/modules root@KURO-BOX:~# tar xvzf /mnt2/u-boot/modules-2.6.20-kuroBOX.tgz ~省略~/ lib/modules/2.6.20-kurobox 수 있는지 확인
root@KURO-BOX:~# ls 2.6.20-kurobox root@KURO-BOX:~# ls 2.6.20-kurobox build modules.dep modules.pcimap kernel modules.ieee1394map modules.symbols modules.alias modules.inputmap modules.usbmap modules.ccwmap modules.isapnpmap source - lenny 네트워크 설정 <br /> 다시 시작하기 전에 네트워크 설정을 해두고, 만약을 위해 고정 IP를 부여
root@KURO-BOX:~# vi /mnt/etc/network/interfaces iface eth0 inet static address 192.168.0.100 network 192.168.0.0 netmask 255.255.255.0 broadcast 192.168.0.255 gateway 192.168.0.1 iface lo inet loopback auto eth0 loroot@KURO-BOX:~# vi /mnt/etc/hosts 127.0.0.1 localhost 192.168.0.100 KURO-BOXroot@KURO-BOX:~# vi /mnt/etc/hosts.allow #ALL: 192.168.0.0/255.255.0.0 #ALL: 127.0.0.1 ALL : ALL : ALLOWroot@KURO-BOX:~# vi /mnt/etc/resolv.conf search nameserver 192.168.0.1 - fstab의 설정을 자동 환경 수정
root@KURO-BOX:~# vi /mnt/etc/fstab # /etc/fstab: static file system information. # # proc /proc proc defaults 0 0 /dev/hda2 none swap sw 0 0 /dev/ hda1 / ext3 defaults,noatime,errors=remount-ro 0 0 /dev/ hda3 /mnt ext3 defaults,noatime 0 0root@KURO-BOX:~# vi /mnt/etc/fstab # /etc/fstab: static file system information. # # proc /proc proc defaults 0 0 /dev/hda2 none swap sw 0 0 /dev/ hda1 / ext3 defaults,noatime,errors=remount-ro 0 0 /dev/ hda3 /mnt ext3 defaults,noatime 0 0root@KURO-BOX:~# vi /mnt/etc/fstab # /etc/fstab: static file system information. # # proc /proc proc defaults 0 0 /dev/hda2 none swap sw 0 0 /dev/ hda1 / ext3 defaults,noatime,errors=remount-ro 0 0 /dev/ hda3 /mnt ext3 defaults,noatime 0 0root@KURO-BOX:~# vi /mnt/etc/fstab # /etc/fstab: static file system information. # # proc /proc proc defaults 0 0 /dev/hda2 none swap sw 0 0 /dev/ hda1 / ext3 defaults,noatime,errors=remount-ro 0 0 /dev/ hda3 /mnt ext3 defaults,noatime 0 0 - EM을지나 다시 시작
EM 모드를 떠나면 쓰기 명령root@KURO-BOX:~# echo -n "OKOK" > /dev/fl3명령 쓸 수 있는지 확인
root@KURO-BOX:~# dd if=/dev/fl3 bs=4 count=1 OKOK1+0 records in 1+0 records out 4 bytes transferred in 0.006583 seconds (608 bytes/sec)다시 시작
root@KURO-BOX:~# reboot - Debian5.0 Lenny 시작 확인
telnet에서 이전에 설정한 IP에 연결 로그인 후 root에 될 수있는 것을 확인Debian GNU/Linux 5.0 KURO-BOX login: tmp-kun Password: tmp-kun ~省略~ tmp-kun@KURO-BOX:~$ suパスワード: root KURO-BOX:/home/tmp-kun#
玄 상자가 DHCP에서 얻은 IP 주소를 확인하여 telnet으로 로그인한다.
Kroutoshikou KURO-BOX (IETSUNA) kernel 2.4.17_kuro-box on ppc KURO-BOX login: root Password: kuro 사쿠라 편집기 업데이트 도구 v2 시스템을 검사하도록 설정
"사쿠라 에디터"도 내부 문자 코드를 Unicode했다 v2 시스템이 공식적으로 발표되었습니다.
이에 따라 설치 지원 툴 "SakuraDown"하지만 v2 시스템을 검사하도록 설정을 변경하여 보았으므로 참고.
다운로드 위치 등을 기술하고있다 "DownInfo.ini"섹션 [EDITOR] 곳을 아래와 같이 편집한다.
[EDITOR] ;ReleaseURI=http://sourceforge.net/api/file/index/project-id/12488/rss?path=%2Fsakura ReleaseURI=http://sourceforge.net/api/file/index/project-id/12488/rss?path=%2Fsakura2 ;FileRegExp=\d\.\d\.\d\.\d/sakura_[^\/\?<>=]+\.zip FileRegExp=\d\.\d\.\d\.\d/sakura2[^\/\?<>=]+\.zip ReleaseFindingPolicy=FROM_LAST ;DownloadURI=http://@MIRROR.dl.sourceforge.net/project/sakura-editor/sakura/@FILE DownloadURI=http://@MIRROR.dl.sourceforge.net/project/sakura-editor/sakura2/@FILE ReleaseType=SITE_SOURCEFORGE ;WildName=sakura_????-??-??*.zip WildName=sakura2-*.zip 정규 표현 라이브러리도 Unicode 버전을 사용하도록 "DownInfo.ini"섹션 [BREGEXP] 곳을 아래와 같이 편집한다.
[BREGEXP] ReleaseURI=http://homepage3.nifty.com/k-takata/mysoft/bregonig.html ;FileRegExp=bron[0-9]+\.zip FileRegExp=bron2[0-9]+\.zip DownloadURI=http://homepage3.nifty.com/k-takata/mysoft/@FILE ReleaseType=SITE_NORMAL WildName=bron???.zip;bron???.lzh 잘못된 부분이 있다고 생각하지만, 일단 이것으로 움직이기 때문에, 잠정 대응은 것으로 자기 책임으로 부탁합니다.
Dynabook C7에 Lubuntu 11.04를 install
이전 Ubuntu Netbook Edition 10.10을 설치 했지만, 작동도 무겁고 쓰기에 문제가 나와 있었기 때문에 변경.
Lubuntu는 Ubuntu 기반 데스크톱을 Gnome에서 LXDE로 변경한 것.
옛날 PC에서 사용하려면 경량으로 정평이있는 LXDE 한데다, 넷북 섬기는 Launcher도 들어있어 낡은 PC인데 세련된 색다른 PC로 탈바꿈합니다.
Lxlauncher가 자동으로 시작하지 않았기 때문에 아래와 같이 파일을 준비하여 다시 시작합니다.
/ home / <username> / .config / autostart / lxlauncher.desktop
[Desktop Entry] Encoding=UTF-8 Name=Lxlauncher Comment=LXDE launcher Exec=/usr/bin/lxlauncher Terminal=false Type=Application Icon= Categories=Application;System; Touch Diamond 환경 구축 참고 그 7
라디오를 사용할 수있게하면 구성 주 
- DLL 교체
안테나의 감도가 조금 좋아지므로 넣어 둔다.
- 1.09.25.23 rilphone.cab 을 Touch Diamond로 전송하여 실행
- Band 제한 해제
원래 상태로는 설정 화의 범위가 87.5 ~ 108.0MHz 그래서 일본의 주파수 대역이다 76.0 ~ 90.0MHz의 일부가 설정할 수 없기 때문에 레지스트리 값을 변경하여 선택 가능하게한다.
- FM_JP.cab 을 Touch Diamond로 전송하여 실행
[HKEY_LOCAL_MACHINE\Software\HTC\FMRadio\FMPlayer] “Band”=dword:0000000 1
- FM_JP.cab 을 Touch Diamond로 전송하여 실행
- 평상시 사용하고있는 이어폰으로 FM 라디오 듣기
오디오 USB 어댑터 "슬림"을 이용하면 함께 제공되는 마이크 이어폰이 아니어도 라디오를들을 수있다.
- 오디오 USB 어댑터 "슬림" 을 주문한다.
Touch Diamond 환경 구축 참고 그 6
SMS와 EMnet 메일 설정에 대해서 쓰고 원하는 요청을 받았기 때문에 기재. 

- ArcMMS 삭제
DelArcMMS.mscr을 실행하여 ArcMMS 관련 삭제
- DelArcMMS.mscr 을 Touch Diamond로 전송하여 실행
(BsB6.5.1G에 MortScript가 이미 들어 있기 때문에 실행시킬 수있다, 할 수없는 경우 MortScript-4.2-PPC.cab 를 설치한 후 실행하십시오.)
- DelArcMMS.mscr 을 Touch Diamond로 전송하여 실행
- MMS Lite 설치 준비
PreSetupMMSLite.exe를 실행 MMS Lite에서 SMS를받을 수 있도록하거나 레지스트리 정보를 기록합니다.
- PreSetupMMSLite.zip 의 압축을 풀고 PreSetupMMSLite.exe을 Touch Diamond로 전송하여 실행
- MSS Lite 설치
MMSLite.1.1.320.wm6.cab를 설치하고 SMS와 MMS를 이용할 수 있도록
- MMSLite.1.1.320.wm6.cab 을 Touch Diamond로 전송하여 실행
- MMSLite 설정
MMSLite.mscr 자신의 환경 맞게 다시 실행하여 설정을 적용
- MMSLite.mscr 다운로드하고 이메일 주소 등을 수정
Case(YES) RegWriteDword( "HKCU", "Software\MMS Lite\Profiles\MMS", "AllowDeliveryReport" , 1 ) RegWriteDword( "HKCU", "Software\MMS Lite\Profiles\MMS", "AllowReadReport" , 1 ) RegWriteDword( "HKCU", "Software\MMS Lite\Profiles\MMS", "AutoRetry" , 1 ) RegWriteString( "HKCU", "Software\MMS Lite\Profiles\MMS", "EmailAddres", " 自分のメールアドレス@emnet.ne.jp " ) RegWriteDword( "HKCU", "Software\MMS Lite\Profiles\MMS", "ForceAutoRecv" , 1 ) RegWriteDword( "HKCU", "Software\MMS Lite\Profiles\MMS", "ForceConnect" , 0 ) RegWriteString( "HKCU", "Software\MMS Lite\Profiles\MMS", "MmsGateway", " 10.56.46.1:8080 " ) RegWriteString( "HKCU", "Software\MMS Lite\Profiles\MMS", "MmsServer", " http://mms.internal.emnet.ne.jp " ) RegWriteDword( "HKCU", "Software\MMS Lite\Profiles\MMS", "MsgDurationPeriod" , 0 ) RegWriteDword( "HKCU", "Software\MMS Lite\Profiles\MMS", "RequireDeliveryReport" , 0 ) RegWriteDword( "HKCU", "Software\MMS Lite\Profiles\MMS", "RetryCount" , 0 ) RegWriteDword( "HKCU", "Software\MMS Lite\Profiles\MMS", "RetryTimeout" , 30 ) RegWriteDword( "HKCU", "Software\MMS Lite\Profiles\MMS", "SaveSent" , 1 ) RegWriteDword( "HKCU", "Software\MMS Lite\Profiles\MMS", "ServerPort" , 80 ) RegWriteString( "HKCU", "Software\MMS Lite\Profiles\MMS\UserAgent", " Default ", " S21HT " ) RegWriteString( "HKCU", "Software\MMS Lite\Profiles\MMS\UserAgent", " S21HT ", " S21HT/ArcSoft-MMSUA-PPC-v50 " ) RegWriteDword( "HKCU", "Software\MMS Lite\Profiles\MMS\Connections", " EMnet " , 0 ) - 수정한 MMSLite.mscr을 Touch Diamond로 전송하여 실행
- MMSLite.mscr 다운로드하고 이메일 주소 등을 수정
- 설정 확인
설정이 반영되어 있는지 확인하는
- "사용하는 연결 선택"에는 EMnet의 것이 선택되었는지
- "이메일 :"에는 전화 번호가 표시되는 것이지만, 레지스트리 정보에 주소가 기록되어 있기 때문에 전송에는 문제없는 것 같지만 신경이 쓰이는 사람은 주소 변경.
Dynabook C7에 Ubuntu Netbook Edition 10.10를 install
이전 Ubuntu Netbook Edition 10.04를 설치 했지만 그 후에 WindowsXP에 다시 있었기 때문에 다시 Ubuntu Netbook Edition 10.10를 설치하려고 화면 설정을 수동으로 할 필요가 있었기 때문에 참고.
xorg.conf 만들기 <br /> 대상이 된 것은 Trident 사의 CyberALADDiN-T 칩셋
- 터미널에서 gedit를 시작
$ gedit ~/xorg.conf - 아래의 내용을 복사 & 페이스트
Section "Monitor" Identifier "Generic Monitor" HorizSync 28-51 VertRefresh 43-60 EndSection Section "Screen" Identifier "Default Screen" Monitor "Generic Monitor" SubSection "Display" Depth 24 Modes "1024x768" "800x600" "640x480" EndSubSection EndSection - 저장 xorg.conf를 / etc/X11에 복사
sudo cp ~/xorg.conf /etc/X11/
[Android] NDK 설치
MacOSXにインストールしたEclipseにAndroid NDKをインストールしたときのメモ。
(ndk-buildコマンド内でmakeコマンドを使用するため、Xcodeなどをインストールしておくこと)
Android NDK のダウンロード
- 下記のファイルをダウンロード
- ダウンロードしたファイルを解凍し、適当なフォルダに格納する(例:User/username/Developer)
CDT(C/C++ Development Tooling)のインストール
- 「ヘルプ」->「新規ソフトウェアのインストール…」を開く
- “作業対象:”に”Helios – http://download.eclipse.org/release/helios”を選択する
- 一覧が表示されたら「プログラミング言語」の中から下記のものにチェックを入れ、インストールする
- C/C++ Development Tools
- C/C++ Library API Documentation Hover Help (インキュベーション)
環境変数の追加
- .bash_profileを開く
- vim ~/.bash_profile
- NDKの格納先を”PATH”に追加(例 NDK格納場所:/Users/username/Developer/android-ndk-mac)
ANDROIDNDK_HOME=/Users/username/Developer/android-ndk-mac PATH=$PATH:${ANDROIDNDK_HOME} - .bash_profileを再読込し、変更を反映させる
- source ~/.bash_profile
- 環境変数が反映されているか確認する
- printenv PATH
- (もし、そもそも環境変数”PATH”が存在してなかったら.bash_profileに下記の一文を最終行に追記する)
export PATH
hello-jniライブラリのビルド
NDKに含まれるサンプルをビルドしてみて環境設定が整っていることを確認する。
- hello-jniのディレクトリに移動(例:/Users/username/Developer/android-ndk-mac/sample/hello-jni/)
- cd /Users/username/Developer/android-ndk-mac/sample/hello-jni/
- ndk-build コマンドでビルドする(成功すると下記のような出力になる)
Gdbserver : [arm-linux-androideabi-4.4.3] libs/armeabi/gdbserver Gdbsetup : libs/armeabi/gdb.setup Compile thumb : hello-jni <= hello-jni.c SharedLibrary : libhello-jni.so Install : libhello-jni.so => libs/armeabi/libhello-jni.so
- 검색
- 피드
- 번역











