# Installing BSD using Windows box (NO-CD)



## eirnym (Oct 23, 2011)

I'm stuck with installing FreeBSD on my fresh computer, because I have only Windows 7 x64. I have box with Windows 7 x64, I have fresh downloaded FreeBSD images. I have LAN and no CD drive at all (on both computers).

The reason why many simple utilities have been stopped to work under Windows 7/Vista is in incompatible security changes described at official site: http://support.microsoft.com/kb/942448

Possible solutions: 

I've already read Handbook, this topic, google and more about this. 
â€ªâ€¬In BSD/Solaris/Mac OS X/Linux this is dd(1). I have no BSD/Linux/etc
â€ªâ€¬UNetBootin. MemStick with Linux works but doesn't with FreeBSD. I have no success with it from Windows XP too.
â€ªâ€¬Use Acronis/Daemon Tools/Nero/UltraISO and etc. - it may be works but they are 
â€¬I have to buy most of them
â€¬They leave to much garbage, so I prefer better solution.

â€ªâ€¬Install Linux â€” it's not good practice to do double work.
â€ªâ€¬Buy CD Drive â€” only for one installation? 
â€ªâ€¬Boot from PXE/TFTP â€” There's lack of NFS server from which I can mount root.
â€ªâ€¬Buy Windows 2008 which has NFS server and can be used to mount root in FreeBSD Boot process â€” only for one installation? 
â€ªâ€¬Install virtual machine such as VirtualBox, install FreeBSD here and write image to flash drive. VirtualBox have very bad USB support.
â€ªâ€¬Buy virtual machine which works good with USB and you able to write image to flash drive under this â€” only for one installation? 
â€ªâ€¬Write my own program - it looks like very complex task.

So, which software can I use to do this task?


----------



## jrm@ (Oct 23, 2011)

Have you tried writing the memstick.img image (on the FreeBSD ftp mirrors) to a memory stick and booting from it and choosing the ftp installation option?  I think you are saying that you are unable to write an image to the memory stick under windows 7.  Can you clarify?


----------



## wblock@ (Oct 23, 2011)

I don't have Windows 7 to test with, but maybe it will help to set the compatibility options for Image Writer.


----------



## eirnym (Oct 23, 2011)

mingrone said:
			
		

> Have you tried writing the memstick.img image (on the FreeBSD ftp mirrors) to a memory stick and booting from it and choosing the ftp installation option?  I think you are saying that you are unable to write an image to the memory stick under windows 7.  Can you clarify?



yes, I unable to write image under Windows 7 x64.


----------



## eirnym (Oct 23, 2011)

There're no software to do this task under Windows 7 x64


----------



## wblock@ (Oct 24, 2011)

What happens with Image Writer?  If it's an "error 8", see this.

This site mentions some other utilities including one called flashnul.  (Untested by me.)


----------



## Neptune (Oct 24, 2011)

there's proprietary soft as UltraISO - it served me well in making bootable flash-drives (its last versions) and it is really sad that it isn't an option for you. As I know, free trial version is available on the oficial site.


----------



## eirnym (Oct 24, 2011)

Many utilities become unusable since security had been changed in Windows Vista. Official information is http://support.microsoft.com/kb/942448
So FlashNul, dd and others becomes unusable.

But I'll give a look to checkout and test others.


----------



## kpa (Oct 24, 2011)

The dd for windows works on vista and windows 7, the trick is to fire up a command prompt using administrator priviledges.


----------



## eirnym (Oct 24, 2011)

kpa said:
			
		

> The dd for windows works on vista and windows 7, the trick is to fire up a command prompt using administrator priviledges.


 It also throws 'Invalid argument' error in my computer. Have you tested to write MBR of one of your HDDs? My Windows 7 always throws back error.

it is fresh Cygwin with *unmounted* HDD (my system drive is PhysicalDrive2):


```
C:\Windows\system32>dd if=//./PhysicalDrive0 of=C:/mbr count=1
1+0 records in
1+0 records out
512 bytes (512 B) copied, 0.003 seconds, 171 kB/s

C:\Windows\system32>dd if=c:/mbr of=//./PhysicalDrive0 count=1
dd: opening `//./PhysicalDrive0': Invalid argument
```


----------



## kpa (Oct 24, 2011)

I've used it only to write image files to USB memory sticks. It's not surprising at all that you can't overwrite the MBR on the system disk on a running system, even FreeBSD uses similar footshooting protection.

Here is how I managed to write the 8.2 AMD64 memstick image to a USB memory stick on windows 7:

I used dd for windows version 0.6beta3 from http://www.chrysocome.net/downloads/dd-0.6beta3.zip

This needs to be run from command prompt that has been started with admin priviledges, right click on command prompt icon in the start menu and select "run as administrator".
`# dd if=c:\FreeBSD-8.2-RELEASE-amd64-memstick.img of=\\?\Device\Harddisk4\Partition0 bs=10240 conv=sync`

The device name for the memory stick I picked up from the output of:

`# dd --list`

Hope this helps.


----------



## eirnym (Oct 24, 2011)

My system drive is PhysicalDrive2 and it can't be unmounted.

Does this image file contains MBR data? 
if yes, your method will not work. if no - how make it bootable?


----------



## wblock@ (Oct 24, 2011)

Just tested Image Writer on Vista 32-bit, no problems either with or without a FAT filesystem already on the memory stick.

Again, exactly what error do you see on Windows 7?


----------



## kpa (Oct 24, 2011)

I assumed you wanted to write the image file to a USB memory stick, no? Writing the memstick image file directly to the system disk in windows won't work, it's not designed to be used like that.


----------



## Zare (Oct 25, 2011)

Don't spread misinformation. It's perfectly working on Windows 7 64-bit (I've used it multiple times). The program or the spawning shell needs to be executed with admin privileges. There is dd for Windows, and rawrite.


----------

