상세 컨텐츠

본문 제목

Raspberry Pi 라즈베리파이 - 외장하드 전원에 대한 고촬

raspberrypi/etc

by ZelKun 2019. 9. 1. 00:44

본문

반응형

 

그동안 공유기 USB포트에 파이를 연결해서 사용하고 있었는데

얼마전까지 잘쓰고 있던 svn, webdav 등등..

서비스가  안되기 시작했다

심지어 연결조차 되질않아 역추적을 하다보니

 

단순하게도 외장하드가 라즈베리에 연결이 안돼 있었다

외장하드가 뻑이난건가 싶어 살펴보니 다행이도 그건아니였고

단순히 파이와 연결이 안될 뿐이었다

 

재부팅을 해보니 외장하드에서 틱틱거리는 소리, 그리고 전원이 나가기를 반복하더니

파이만 부팅되거나 파이도 부팅이 안됬다

 

왜냐하면 시간이 지나도 라즈비안이 올라오질 않았다…

결국 sd카드를 PC 연결해서 파일시스템 검사를 해서 복구해줬다..

 

결론적으로 외장하드 전력을 못 받쳐줘서 생기는 문제였다

그동안 하드가 뻑나고 했던게 전력이 모자라서 였을것 같다는 생각과

 

파이의 전력 제한을 풀어주는 max_usb_current=1 옵션이 의미가 있나 싶어졌다

그래도 혹시나 싶어 Y 케이블을 주문해서 연결해봤다

 

Dual USB3.0 A Male to Micro USB 3.0 Y cable with Extra Power

참고로 전력 제한을 푸는 

boot/config.txt 파일 상단에

max_usb_current=1 이라고 넣어주면 된다

pi@rasp-dev:~ $ cat /boot/config.txt

 

max_usb_current=1

 

# For more options and information see

http://rpf.io/configtxt

# Some settings may impact device functionality. See link above for details

 

# uncomment if you get no picture on HDMI for a default "safe" mode

#hdmi_safe=1

 

# uncomment this if your display has a black border of unused pixels visible

# and your display can output without overscan

#disable_overscan=1

 

# uncomment the following to adjust overscan. Use positive numbers if console

# goes off screen, and negative if there is too much border

#overscan_left=16

#overscan_right=16

#overscan_top=16

#overscan_bottom=16

 

# uncomment to force a console size. By default it will be display's size minus

# overscan.

#framebuffer_width=1280

#framebuffer_height=720

 

# uncomment if hdmi display is not detected and composite is being output

#hdmi_force_hotplug=1

 

# uncomment to force a specific HDMI mode (this will force VGA)

#hdmi_group=1

#hdmi_mode=1

 

# uncomment to force a HDMI mode rather than DVI. This can make audio work in

# DMT (computer monitor) modes

#hdmi_drive=2

 

# uncomment to increase signal to HDMI, if you have interference, blanking, or

# no display

#config_hdmi_boost=4

 

# uncomment for composite PAL

#sdtv_mode=2

 

#uncomment to overclock the arm. 700 MHz is the default.

#arm_freq=800

 

# Uncomment some or all of these to enable the optional hardware interfaces

#dtparam=i2c_arm=on

#dtparam=i2s=on

#dtparam=spi=on

 

# Uncomment this to enable the lirc-rpi module

#dtoverlay=lirc-rpi

 

# Additional overlays and parameters are documented /boot/overlays/README

 

# Enable audio (loads snd_bcm2835)

dtparam=audio=on

pi@rasp-dev:~ $ 

전력제한 설정을 하면 USB(4포트 통합) 0.6A에서 2배인 1.2A 전압이 올라가는데

이미 설정해서 쓰고 있긴 했다

근데 pi2에서 max_usb_current=2  써왔는데 문서를 보니 2 없고 1인듯...

 

암튼 Y케이블로 변경해서 부팅을 시도했지만

결국엔 외장하드가 다시 꺼지는 소리가 났다

실패…

 

파이에 들어가는 전압이 낮으니 외장하드에 보내줄 전력이 모자란  하다

 

외장하드에 보조전원을 달아주려고 했는데

생각해보니 Pi 2A 전력을 물려주면 되는 일….

5v 2A 전력에 파이를 물려주니 틱틱거리는 소리도 없고

서비스도   올라온다..

 

외장하드를 2개이상 쓸거면 유전원 USB 권장한다

 

참고

https://elinux.org/RPiconfig#Boot

https://www.raspberrypi.org/forums/viewtopic.php?t=105502

반응형

관련글 더보기

댓글 영역