|
FreeBSD General Other questions regarding FreeBSD which do not fit in any of the categories below. |
|
Thread Tools | Display Modes |
|
|||
hello, how BSD reboot but keep memory
i want to do this: before BSD reboot, my program wrote same data in memory, after reboot, my loader program read this data from memory, so i need bios not clear memory.
how can i do, have someone give me a advice? so thanks |
|
||||
Clearing RAM on a boot sequence is hardware specific. Some platforms wipe, others do not.
I have an older server that does not wipe on boot; it uses an older AMD Socket 7 motherboard. I run OpenBSD on that server, it retains any prior dmesg buffer found at boot time, just in case it may be needed. |
|
|||
You can write your own bios and burn your own rom to do that but then each box would need their own copy of that.
|
|
||||
Quote:
Questions of how to do that in a program, are more relevant to programming (in your programming language) or unix in general.
__________________
My Journal Thou shalt check the array bounds of all strings (indeed, all arrays), for surely where thou typest ``foo'' someone someday shall type ``supercalifragilisticexpialidocious''. |
|
|||
Theoretically, one way of doing that would be to dump core like debugging tools do and then later create a new process and inject the appropriate parts of the core dump into it in order to rerun the program.
But I don't think there are any software available that allow you to do that. And by the way, yes, some (many?) machines don't clear memory after a reboot. Some BIOSs clear it only when they do the "full memory check" or have the "quick POST" option disabled.
__________________
May the source be with you! Last edited by Beastie; 10th October 2011 at 08:09 PM. |
|
||||
While it may be possible after some tricks and wizardry, you have to wonder if there's not an easier way to accomplish the same end result...
__________________
UNIX was not designed to stop you from doing stupid things, because that would also stop you from doing clever things. |
|
|||
answer
I have changed the BSD's code in "biostramp.S", in middle of this file, I reload MBR to 0x7C00, and jmp to 0000:7C00, but my computer crashed, maybe dead in "ntldr", thus, couldn't into windows.
|
|
|||
OpenBSD's MBR already relocates itself, what exactly are you trying to do? if you're attempting to have a piece of software in memory after the OpenBSD kernel loads, you'll need to modify the BIOS provided memory map to exclude that area.
After the kernel loads, you're dealing with a paged protected memory system, processes work with virtual addresses. |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
reboot freebsd periodically | semarmendemx | FreeBSD General | 3 | 27th October 2010 04:23 AM |
Apply TTYS changes with out reboot | jjjustjjjay | OpenBSD General | 1 | 6th May 2010 09:24 PM |
problem to first reboot after installation | openbsd | OpenBSD Installation and Upgrading | 3 | 16th May 2009 06:30 PM |
Reboot loop on 7.0 upgraded to 7.1 | EricM | FreeBSD Installation and Upgrading | 3 | 25th March 2009 04:25 AM |
Instant reboot with 7.0-RELEASE | davidgurvich | FreeBSD Installation and Upgrading | 5 | 4th June 2008 08:15 PM |