LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 10-31-2010, 06:59 PM   #1
ankit_justdoit
LQ Newbie
 
Registered: Oct 2010
Posts: 2

Rep: Reputation: 0
unable to seek on /dev/loop0


Hello,

Whenever i execute command fdisk /dev/loop0 < file1
(file1 contains the commands used for fdisk),I get an error saying "unable to seek on /dev/loop0".The last line of file1 contains w in order to write the partition table back to the disc.

How should I exit the command prompt safely (after saving all the settings)

Below are the contents of the file



filef.sh:

fdisk /dev/loop0 < filee
fdisk /dev/loop0 < file1


filee:
x
s
8
h
16
c
1024
r
d
n
p
1

512
t
b
p
w



file1:
x
c
1024
r
n
e
2


n
l

700
n
l

900
n
l


t
5
fd
t
6
fd
t
7
fd
p
w
 
Old 10-31-2010, 07:29 PM   #2
Samotnik
Member
 
Registered: Jun 2006
Location: Belarus
Distribution: Debian GNU/Linux testing/unstable
Posts: 471

Rep: Reputation: 40
You should execute fdisk on your actual device file (or regular file, which contains partition). Loopfile contains nothing by itself.
 
1 members found this post helpful.
Old 11-01-2010, 07:40 AM   #3
ankit_justdoit
LQ Newbie
 
Registered: Oct 2010
Posts: 2

Original Poster
Rep: Reputation: 0
Thanks a lot..it worked but the message "syncing disks" is displayed at the end of executing and it is not giving me back the command prompt.what additional command do i need to put in file1 to terminate safely to my command prompt..??
 
  


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
Unable to seek on /dev/sda athreyavc Linux - Desktop 7 01-21-2008 01:16 PM
unable to seek on /dev/hda santhosh23 Linux - Hardware 1 01-11-2007 10:32 PM
Fdisk Error: "Unable to seek on /dev/hdb vidguy Linux - General 4 02-17-2006 11:36 PM
Error: "Unable to seek on /dev/hdb" vidguy Linux - Hardware 2 02-15-2006 02:34 AM


All times are GMT -5. The time now is 04:52 PM.

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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration