LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware > Linux - Embedded & Single-board computer
User Name
Password
Linux - Embedded & Single-board computer This forum is for the discussion of Linux on both embedded devices and single-board computers (such as the Raspberry Pi, BeagleBoard and PandaBoard). Discussions involving Arduino, plug computers and other micro-controller like devices are also welcome.

Notices



Reply
 
Search this Thread
Old 06-16-2011, 07:09 AM   #1
elemaniaq
LQ Newbie
 
Registered: Jun 2011
Posts: 2

Rep: Reputation: Disabled
Question "Late Saving" Problem


Hello,

Im working on I.MX28 dev board and using kernel 2.6.35 on it. The problem is that when i created a file and echo some text to it, i can see content of the file in the correct form. After this operations, if i restart my board with poweroff command , i can see file and its content again. But if i restart my board hardly(with reset button), i can see the file but it contains nothing.

How can I solve the "late saving" problem ?

Regards,
Snan
 
Old 06-16-2011, 08:35 AM   #2
business_kid
Guru
 
Registered: Jan 2006
Location: Ireland
Distribution: Slackware & Android
Posts: 6,619

Rep: Reputation: 585Reputation: 585Reputation: 585Reputation: 585Reputation: 585Reputation: 585
Try
cat >> your_file <<EOF, which should return
>
type or paste your text there. When you press return, you get another
>
When you simply type EOF, the whole thing should be saved off.
 
Old 06-16-2011, 09:25 AM   #3
MTK358
LQ 5k Club
 
Registered: Sep 2009
Posts: 6,443
Blog Entries: 3

Rep: Reputation: 714Reputation: 714Reputation: 714Reputation: 714Reputation: 714Reputation: 714Reputation: 714
Do you have a good reason to improperly shut down Linux?

There are other files that this could also happen to. Also, if it happened to be writing to the hard drive while you turned off the power, it might corrupt your filesystem.
 
Old 06-17-2011, 07:40 AM   #4
elemaniaq
LQ Newbie
 
Registered: Jun 2011
Posts: 2

Original Poster
Rep: Reputation: Disabled
business_kid,

Thank you for your reply.i tried, it works !

MTK358,

my project will be used on the vehicles and it will shut down if the driver stops engine.

Last edited by elemaniaq; 06-17-2011 at 08:21 AM.
 
Old 06-17-2011, 08:59 AM   #5
MTK358
LQ 5k Club
 
Registered: Sep 2009
Posts: 6,443
Blog Entries: 3

Rep: Reputation: 714Reputation: 714Reputation: 714Reputation: 714Reputation: 714Reputation: 714Reputation: 714
If the thread is solved, mark it as solved.
 
Old 06-17-2011, 10:46 AM   #6
TobiSGD
Moderator
 
Registered: Dec 2009
Location: Hanover, Germany
Distribution: Main: Gentoo Others: What fits the task
Posts: 15,653
Blog Entries: 2

Rep: Reputation: 4095Reputation: 4095Reputation: 4095Reputation: 4095Reputation: 4095Reputation: 4095Reputation: 4095Reputation: 4095Reputation: 4095Reputation: 4095Reputation: 4095
Quote:
Originally Posted by elemaniaq View Post
my project will be used on the vehicles and it will shut down if the driver stops engine.
Wouldn't it be better to do a proper shutdown when the driver stops the engine?
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Question/Suggestion - about saving a "subscribed thread" in more than one folder? GrapefruiTgirl LQ Suggestions & Feedback 1 09-14-2009 12:27 PM
scrambled display after entering "power saving?" state rbees Linux - General 2 02-26-2008 06:32 AM
Debian "testing" -- lots of bug reports of late? vharishankar Debian 5 10-15-2006 02:34 AM
Is it too late to retire "spam" as the noun for unsolicietd e-mail? PTrenholme General 1 11-09-2005 05:41 PM
A "late collision" every 2-3 seconds RedDwarf Linux - Networking 2 08-16-2004 06:47 AM


All times are GMT -5. The time now is 01:40 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration