Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature Request] Disk Maker under macOS #3

Closed
chromer030 opened this issue Apr 9, 2020 · 16 comments
Closed

[Feature Request] Disk Maker under macOS #3

chromer030 opened this issue Apr 9, 2020 · 16 comments

Comments

@chromer030
Copy link

Thank you for this great and useful project
can we expect macOS version ??

@ventoy
Copy link
Owner

ventoy commented Apr 9, 2020

Thank you for your support! Limited to my development environment, the macOS version is not currently in my plan. I'm so sorry!

@chromer030
Copy link
Author

Thank you again , i hope this project shall continue to become the best one in the world.

@codinginpython123
Copy link

codinginpython123 commented Apr 21, 2021

for mac os support you can use the diskutil command

The syntax is:
diskutil partitionDisk /dev/disk PartitionTable Filesystem Name Size

For example:
diskutil partitionDisk /dev/disk GPT MS-DOS NewPartition 10g
MS-DOS(FAT-32)

@ssbarnea
Copy link

Made it working using a virtualbox box vm with iso booter and mounting the usb stinck in it, but there is no joy as usb mounting requires oracle extensions. Worst part is that i cannot test the stick in a vm because virtualbox does not allow booting from them, but once i put it on a machine it worked.

@Andrew-J-Larson
Copy link

@ssbarnea

Made it working using a virtualbox box vm with iso booter and mounting the usb stinck in it, but there is no joy as usb mounting requires oracle extensions.

I actually made a little tutorial for that situation: #35 (comment)

Worst part is that i cannot test the stick in a vm because virtualbox does not allow booting from them, but once i put it on a machine it worked.

VirtualBox does support booting from USB's, see: #35 (comment)

@WombleWoo7547
Copy link

Download the ISO from ventoy's website (https://www.ventoy.net/en/download.html)

Then use BalenaEtcher (https://www.balena.io/etcher) to flash the ISO to a usb drive :)

@Andrew-J-Larson
Copy link

Download the ISO from ventoy's website (https://www.ventoy.net/en/download.html)

Then use BalenaEtcher (https://www.balena.io/etcher) to flash the ISO to a usb drive :)

This isn't what people are asking for. They want a solution that allows staying within MacOS and applying Ventoy to a USB device.

@WombleWoo7547
Copy link

WombleWoo7547 commented Feb 19, 2023 via email

@Andrew-J-Larson
Copy link

Yes, that will do that. Just use the ISO, it'll do the same thing as the ventoy loader. The ventoy app basically just applies the ISO anyway. I'm not sure what you mean, or if you don't understand ISOs or installers or ventoy itself. Ventoy is (I think) a kernel-less operating system, that starts the ISO

On Wed, Feb 15, 2023 at 5:25 PM Drew @.> wrote: Download the ISO from ventoy's website ( https://www.ventoy.net/en/download.html) Then use BalenaEtcher (https://www.balena.io/etcher) to flash the ISO to a usb drive :) This isn't what people are asking for. They want a solution that allows staying within MacOS and applying Ventoy to a USB device. — Reply to this email directly, view it on GitHub <#3 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/ARNF4C43GXO6YMYDARZ73MTWXUGR5ANCNFSM4MEYXADA . You are receiving this because you commented.Message ID: @.>

My point is that people don't want to shutdown MacOS to boot up this USB to then apply to another USB... It adds more time wasting steps than if it could run natively.

@bitmvr
Copy link

bitmvr commented May 23, 2023

@TheAlienDrew ,

I've been breaking down the important steps of the Linux Installer to understand everything it's doing to get an minimum viable product working for MacOS.

VentoyWorker.sh is the workhorse. It's handling the formatting and partitioning. It's also harnessing dd to write the following *.img files to the target disk.

  • boot.img
  • core.img
  • ventoy.disk.img

I'm not super familiar with building these things from scratch, therefore I am a bit confused by why a UUID is being written to disk. Is that required?

The function vtoy_gen_uuid is called here at line 353 within VentoyWorker.sh. That function resides in the custom library available on lib

https://github.com/ventoy/Ventoy/blob/master/INSTALL/tool/VentoyWorker.sh#L353

@Andrew-J-Larson
Copy link

Andrew-J-Larson commented May 23, 2023

@TheAlienDrew ,

I've been breaking down the important steps of the Linux Installer to understand everything it's doing to get an minimum viable product working for MacOS.

VentoyWorker.sh is the workhorse. It's handling the formatting and partitioning. It's also harnessing dd to write the following *.img files to the target disk.

  • boot.img
  • core.img
  • ventoy.disk.img

I'm not super familiar with building these things from scratch, therefore I am a bit confused by why a UUID is being written to disk. Is that required?

The function vtoy_gen_uuid is called here at line 353 within VentoyWorker.sh. That function resides in the custom library available on lib

https://github.com/ventoy/Ventoy/blob/master/INSTALL/tool/VentoyWorker.sh#L353

My best bet is that it probably uses the UUID in order for it to rightfully detect and update the ventoy partition.

The with your little journey of trying to recreate ventoy for Mac OS, you're likely going to run into the same issue I've already had, where there's not a viable option yet to create some of the partitions that require proprietary file systems (unless things have changed with some of the brew packages that allow for creating, reading, and writing these proprietary file systems).

@bitmvr
Copy link

bitmvr commented May 23, 2023

Based on limited research it appeared the NTFS related things were not required, perhaps I read the code wrong. What is needed that we cannot create? I thought we could get around everything by just using ExFAT which we can create through diskutil as well as adding an MBR or GPT boot partition.

@bitmvr
Copy link

bitmvr commented May 23, 2023

Bear in mind this is a flowchart generated from ChatGPT based on VentoyWorker.sh It's missing a few things if the disk isn't valid based on a quick view, but has been helpful in quickly understanding exactly what we're doing.

graph LR
A[Start] --> B{Command Line Arguments}
B -- "-i" --> C[Install Mode]
C -- Existing Ventoy Version --> D[Force Install?]
D -- Yes --> E[Perform Installation]
D -- No --> F[Print Error Message and Exit]
B -- "-I" --> G[Force Install Mode]
G --> E[Perform Installation]
B -- "-u" --> H[Update Mode]
H --> I[Perform Update]
B -- "-l" --> J[List Mode]
J --> K[Retrieve Ventoy Version and Disk Info]
K --> L[Print Ventoy Information]
B -- Invalid Argument --> M[Print Usage Instructions and Exit]
M --> N[Exit]
E --> O[Perform Disk Checks]
O -- Disk Valid? --> P[Perform Disk Operations]
P --> Q[Format Disk]
Q --> R[Create Partitions]
R --> S[Install Ventoy Files]
S --> T[Sync Data]
T --> U[Finish Installation]
U --> N[Exit]
H --> V[Print Error Message and Exit]
V --> N[Exit]
I --> V
N --> End[End]
Loading

@Andrew-J-Larson
Copy link

Andrew-J-Larson commented May 23, 2023

Based on limited research it appeared the NTFS related things were not required, perhaps I read the code wrong. What is needed that we cannot create? I thought we could get around everything by just using ExFAT which we can create through diskutil as well as adding an MBR or GPT boot partition.

This is the reason why it won't work (not because of exFAT or NTFS):

#35 (comment)

@bitmvr
Copy link

bitmvr commented May 23, 2023

@TheAlienDrew ,

My apologies, but I am clearly missing something. I read through that thread and saw you eventually get to where you're using VirtualBox to get a functioning Ventoy USB created. I do not see anywhere in the code that would prevent this from happening outside of my own struggling to follow/understand block offsets and seeks settings and why they were chosen as the code doesn't have comments explaining those values, a lack of experiencing on my end working with disks at that level.

I am very okay with having limited functionality that only works if the disk is formatted with supported filesystem, which exFAT is the most generally supported.

@Andrew-J-Larson
Copy link

@TheAlienDrew ,

My apologies, but I am clearly missing something. I read through that thread and saw you eventually get to where you're using VirtualBox to get a functioning Ventoy USB created. I do not see anywhere in the code that would prevent this from happening outside of my own struggling to follow/understand block offsets and seeks settings and why they were chosen as the code doesn't have comments explaining those values, a lack of experiencing on my end working with disks at that level.

I am very okay with having limited functionality that only works if the disk is formatted with supported filesystem, which exFAT is the most generally supported.

Look in the CreatePersistentImg.sh. For those of us that require that feature, which will be a good many I assume, ventoy without this feature would pretty much be just as good as using any other multiboot program that doesn't have the feature built in. But the only options for creating a persistent image file are those with the filesystem formats: EXT[2/3/4] or XFS.

Similarly for those with ventoy USBs already setup, there would also be an inability to resize those persistent images (see ExtendPersistentImg.sh).

There's also a portion in VentoyWorker.sh that checks for EXT files systems, for some partition size manipulation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants