셧다운 없이 바로 전원을 꺼버리는 경우.. 안전 대책은?
글쓴이: sadtale / 작성시간: 화, 2010/08/03 - 9:16오후
우분투를 사용중인데요....
이걸.. 전원이 아니라 밧데리를 연결해서 사용하는데..
밧데리 체크가 안되는 상황이라.. 언제라도 확 꺼질 수 있는 상황인데요..
셧다운 없이 바로 확 꺼져버리면 버퍼가 날아가버려서 파일 시스템이 깨질 우려가 있잖아요..
이걸 막을 방법이 없을까요?
그냥 버퍼를 안써버리면 무지 느려질 것 같고...
임베디드 시스템에서는 이런 경우 어떻게 처리되는지 모르겠네요..
아무래도 임베디드 리눅스의 경우 비정상적으로 전원을 제거하는 경우가 많지 싶은데..
어찌됐든 전 일반 우분투를 사용중이구요..
이런 경우.. 어떻게든 밧데리 체크를 해서 미리미리 셧다운을 시켜줘야 할까요?
아.. 고민이네요..
Forums:
피할수 없는
피할수 없는 상황이면 파일시스템을 잘 고르셔야겠네요.
저널링 말고도 이런걸 위해서 특화되어 나온 파일시스템도 있을 것 같아요.
------식은이 처------
길이 끝나는 저기엔 아무 것도 없어요. 희망이고 나발이고 아무 것도 없어.
From my experience,
(sorry for writing in English.. There's no way to type Korean here)
From my experience, the embedded device that I was developing on was just used virtual filesystem on its RAM. It extracts actual data from packed data on FlashRom while booting. That means, it was okay even when the users remove power at any time, except of saving data to FlashROM. (just imagine "Firmware updates". Every mobile or embedded device says "Don't power off while firmware updating".) Even when the user shut down while saving data and the data is corrupted, the device reset the saved data to default values during next booting by inspecting "checksum". It's obvious better off to use default data instead of corrupted data.
So I suggest you not to use HDD-style media but just virtual (volatile) filesystem on RAM.
Or, how about using a digital voltage meter (or A/D converter) connected to serial ports? Voltage itself doesn't guarantee the status of battery exactly, but it must be helpful. Check the voltage periodically via a daemon, then if the voltage level is lower than critical level, just send an alert somewhere and shut down the system. (Mobile devices use this kinda measuring.) This must be an ideal solution unless you cannot use more money at all.
--
This is for you new people. I have just one rule :
Everyone fights, no one quits. If you don't do your job, I'll shoot you myself. Do you get me?
--
barrier 켜고
barrier 켜고 마운트하세요. 디폴트로 켜져있지 않나요 근데?
하드에 베드섹터
하드에 베드섹터 날수 잇습니다
mirheekl님 말대로 live usb같은걸로 사용하시거나
usb에 우분투를 깔아버려도 되죠 (usb 용량만 된다면 설치됩니다. 설치법은 구글링을..)
임베디드 리눅스라면
임베디드 리눅스라면 배터리가 체크되는 제품을 사용하거나 체크할수 있는 코드를 포팅하겠지요...
저널링 파일시스템을
저널링 파일시스템을 사용하면 파일 시스템은 보호됩니다. 파일은 ...
OTL
댓글 달기