Hi,
Is there any way to capture the boot record information on the disk?
For example, assume that I have 3 different operating systems installed
on a hard drive. I want to be able to run a program/utility and get the
boot record information, like address on the drive or contents at that
specific location, for all the 3 operating systems.
Is this possible using C?
Thanks in advance,
Ravi 8 1184
"Ravi" <ra****************@gmail.com> wrote in message
news:11**********************@o13g2000cwo.googlegr oups.com... Hi,
Is there any way to capture the boot record information on the disk? For example, assume that I have 3 different operating systems installed on a hard drive. I want to be able to run a program/utility and get the boot record information, like address on the drive or contents at that specific location, for all the 3 operating systems.
Is this possible using C?
Thanks in advance, Ravi
That's more of an operating system question than a C question.
Under Linux you would just open /dev/hda (replace hda with the device
name of the drive you want to look at) as a file and start reading
from it.
Can't we program that using assembly language and C?
I want capture the boot record binary into a variable. In Linux
everything is a file. So it is easy there to get that information. Let
us talk about Windows. How can I do it in Windows?
In article <11*********************@f14g2000cwb.googlegroups. com>,
Ravi <ra****************@gmail.com> wrote: Can't we program that using assembly language and C?
Perhaps, but assembly language is not C and this is a C newgroup.
You mention "Intel Architecture" in your subject heading, but you
should realize that Intel makes hundreds of different CPUs
with different assembly languages.
I want capture the boot record binary into a variable. In Linux everything is a file.
Urr, no it isn't. You cannot, for example, create a new
file by simply appending something to a directory -- something which
you would be able to do if "everything is a file" since then
a directory would be a file.
Most of /proc are *pseudo-files* rather than files.
So it is easy there to get that information. Let us talk about Windows. How can I do it in Windows?
That would seem to me more appropriate to ask in a Windows newsgroup.
--
Look out, there are llamas!
On 18 May 2005 09:57:26 -0700, "Ravi" <ra****************@gmail.com>
wrote: Can't we program that using assembly language and C? I want capture the boot record binary into a variable. In Linux everything is a file. So it is easy there to get that information. Let us talk about Windows. How can I do it in Windows?
Why don't you ask on a Windows programming group?
--
Al Balmer
Balmer Consulting re************************@att.net
Ravi wrote: Can't we program that using assembly language and C? I want capture the boot record binary into a variable. In Linux everything is a file. So it is easy there to get that information. Let us talk about Windows. How can I do it in Windows?
Under windows you can do the same thing. Open the disk as a raw device
and read from it. You should go to the Microsoft site and search the
documentation. Specifically look for the API CreateFile and look at
the documentation for Physical Disks and Volumes in there.
In article <11**********************@o13g2000cwo.googlegroups .com>,
Ravi <ra****************@gmail.com> wrote: Hi,
Is there any way to capture the boot record information on the disk? For example, assume that I have 3 different operating systems installed on a hard drive. I want to be able to run a program/utility and get the boot record information, like address on the drive or contents at that specific location, for all the 3 operating systems.
Is this possible using C?
Everyone will tell you that this is OT for this newsgroup, but there is
a simple, concise, on-topic, accurate and all-inclusive answer to your
question. The answer is given below...
SPOILER SPACE
SPOILER SPACE
SPOILER SPACE
SPOILER SPACE
SPOILER SPACE
SPOILER SPACE
SPOILER SPACE
SPOILER SPACE
SPOILER SPACE
SPOILER SPACE
SPOILER SPACE
SPOILER SPACE
SPOILER SPACE
SPOILER SPACE
SPOILER SPACE
SPOILER SPACE
SPOILER SPACE
SPOILER SPACE
SPOILER SPACE
SPOILER SPACE
Yes.
"Ravi" <ra****************@gmail.com> wrote Can't we program that using assembly language and C? I want capture the boot record binary into a variable. In Linux everything is a file. So it is easy there to get that information. Let us talk about Windows. How can I do it in Windows?
The answer is that ANSI C doesn't allow this sort of low-level interaction
with the disk drive. However typically C compilers come with libraries of
platform-specific functions which can do all sorts of useful things.
Assemblers generally allow you to do even more. You need to ask in a group
devoted to your platform about this, not here.
Oops.....I did not even think about all these responses. Malcolm's
answer was simple and straight forward....anyways...thanks guys....
Ravi This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: Subrahmanyam Arya |
last post by:
Hi Folks ,
I am trying to solve the problem of reading the numbers correctly
from a serial line into an intel pentium processor machine .
I am reading 1 byte and 2byte data both positive...
|
by: Ozo |
last post by:
What would be the C++ compiler producing the fastest code for Windows
XP Pro (32-bit)? I have to choose between these two:
- Visual C++ 2005 compiler
- Intel C++ Compiler 9.0 for Windows
My...
|
by: diffuser78 |
last post by:
I just started to write a small project in Python. I was wondering if
there can be something like remote boot manager.
I have to remotely start a computer. It has dual boot (WinXP and
Linux)....
|
by: =?Utf-8?B?Um9iIFY=?= |
last post by:
I am trying to reformat my XP professional to start from scratch. However,
when attempting to do so, I discover that I have an invalid boot.ini. When I
go to recover and rebuild my boot.ini file in...
|
by: Alan |
last post by:
Hi List!
I have I Macbook Pro Intel running OSX 10.4.10.
I downloaded Python 2.5 and tried
TclTkAquaBI-8.4.10.0.dmg, but I got:
Traceback (most recent call last):
File "<stdin>", line 1,...
|
by: monirul arfin |
last post by:
Hi all,
My computer cannot boot from cd. I want to format my all drives, but when I insert CD in the DVD drive & restart my computer, it will restart without booting from CD & it not shows the...
|
by: jlm699 |
last post by:
Greetings friends,
It's been a while since I've visited this C/C++ forum, and as expected my C++ is unacceptably rusty. Recently I've been reading about Master Boot Records (MBR) and the boot...
|
by: Chris Calloway |
last post by:
Triangle (NC) Zope and Python Users Group (TriZPUG) is proud to open
registration for our fourth annual ultra-low cost Plone and Python
training camps, BootCampArama 2008:
...
|
by: jhc0033 |
last post by:
My experience has generally been that, for CPU-intensive tasks, the
Intel compiler produces code that is about as fast as that produced by
the Gnu compiler.
However, on this simple Shootout...
|
by: emmanuelkatto |
last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud.
Please let me know.
Thanks!
Emmanuel
|
by: nemocccc |
last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
|
by: Sonnysonu |
last post by:
This is the data of csv file
1 2 3
1 2 3
1 2 3
1 2 3
2 3
2 3
3
the lengths should be different i have to store the data by column-wise with in the specific length.
suppose the i have to...
|
by: Hystou |
last post by:
There are some requirements for setting up RAID:
1. The motherboard and BIOS support RAID configuration.
2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers,...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
| |