Comments (9)
Hi Mic,
- Did you follow these steps? You have to ensure the admin permission.
- Did you use the correct disk number? From the error, it seems not EXT4 file system. Disk number "8" seems not correct. Normally, PC has 4 SATA ports and few USB ports. Are you sure you have 8 physical disks installed?
Best regards,
Nick
from sharpext4.
Hi Nick,
its correct, I have 8 Disks on my machine (XEON Workstation with 10 Sata Ports) I admit this is not a mainstream computer :)
I did the steps you mentioned in 1), but it seems that I have a PlatformToolset issue. V142 is missing on my computer. I found this after abandoning Visual Studio and starting Jetbrains Rider. The error messages there are far more understandable.
I will try to fix this and come back to you with the result asap.
Best regards
Mic
from sharpext4.
Hi Nick,
sorry not replying for so long. I was absorbed by other parts of my project. Now I am back on the Linux issue.
I guess my problem is, how i compile. When compiling the lwext4 lib a lot of conversion warnings arrise with lots of "possible loss of data".
My properties in VS2019:
Windows SDK Version 10.0
Platform Toolset Visual Studio 2019 (v142)
C++ Language Standard ISO C++ 14
C Language Standard Legacy MSVC
How are your settings when compining and building the Sample App?
Best
Mic
from sharpext4.
Hi Nick, sorry not replying for so long. I was absorbed by other parts of my project. Now I am back on the Linux issue. I guess my problem is, how i compile. When compiling the lwext4 lib a lot of conversion warnings arrise with lots of "possible loss of data". My properties in VS2019: Windows SDK Version 10.0 Platform Toolset Visual Studio 2019 (v142) C++ Language Standard ISO C++ 14 C Language Standard Legacy MSVC
How are your settings when compining and building the Sample App?
Best Mic
It shouldn't be a problem. Can you try another PC with fewer disks or follow the steps earlier?
from sharpext4.
I have a laptop and will try this.
from sharpext4.
Hi Nick,
finally I managed to run the Sample on my laptop. For that I modified the Sample Program.cs to access a physical disk:
My laptop has a gpt formatted disk 0 with partitions for Windows and linux and a mbr formatted disk 1 with one windows partition on it.
Calling the sample.exe for disk 0 I get:
C:\Users\Mic\RiderProjects\SharpExt4\Sample\bin\Debug>Sample.exe 0 1 Partition 0 : SharpExt4.Partition EXCEPTION: Could not mount partition. Partition 0 : SharpExt4.Partition EXCEPTION: Could not register partition. Partition 0 : SharpExt4.Partition EXCEPTION: Could not register partition. Partition 0 : SharpExt4.Partition EXCEPTION: Could not register partition.
Only four partitions are found, but the disk contains more partitions:
`DISKPART> sel disk 0
Datenträger 0 ist jetzt der gewählte Datenträger.
DISKPART> list part
Partition ### Typ Größe Offset
Partition 1 System 190 MB 1024 KB
Partition 2 Reserviert 128 MB 191 MB
Partition 3 Primär 156 GB 319 MB
Partition 4 Primär 67 GB 156 GB
Partition 5 Unbekannt 1907 MB 223 GB
Partition 6 Unbekannt 119 GB 225 GB
Partition 7 Unbekannt 119 GB 345 GB
Partition 8 Unbekannt 238 GB 464 GB
Partition 9 Primär 230 GB 702 GB
Partition 10 Wiederherstellun 990 MB 933 GB
Partition 11 Wiederherstellun 18 GB 933 GB
Partition 12 Wiederherstellun 1644 MB 952 GB`
Partition 10,11 and 12 are from the Laptop Manufacturer.
Partition 5,6,7,8 are the Linux partitions which I want to mount
Partition 3,4,9 are the Windows partitions (Windows 10)
So the question is:
Is there a problem when building the lib and the exe (when compiling I got a lot of conversion warnings)?
Do I access the disk in a wrong way?
Best
Mic
from sharpext4.
I haven't tested for Linux on gpt disk. You can try a USB flash drives with Linux partition.
from sharpext4.
I created an MBR formatted USB stick with one ext4 partition on it with my linux system.
Then I booted Windows again and plugged in the stick. Using the Sample.exe gives:
C:\Users\Mic\RiderProjects\SharpExt4\Sample\bin\Debug>Sample.exe 2 1 Partition 61529391104 : SharpExt4.Partition EXCEPTION: Could not mount partition. Partition 0 : SharpExt4.Partition EXCEPTION: Could not register partition. Partition 0 : SharpExt4.Partition EXCEPTION: Could not register partition. Partition 0 : SharpExt4.Partition EXCEPTION: Could not register partition.
Now I can see the size of the partition, but again it lists me 4 partition even if there is only one on the disk.
And a mount is not working: "EXCEPTION: Could not mount partition"
from sharpext4.
I created an MBR formatted USB stick with one ext4 partition on it with my linux system. Then I booted Windows again and plugged in the stick. Using the Sample.exe gives:
C:\Users\Mic\RiderProjects\SharpExt4\Sample\bin\Debug>Sample.exe 2 1 Partition 61529391104 : SharpExt4.Partition EXCEPTION: Could not mount partition. Partition 0 : SharpExt4.Partition EXCEPTION: Could not register partition. Partition 0 : SharpExt4.Partition EXCEPTION: Could not register partition. Partition 0 : SharpExt4.Partition EXCEPTION: Could not register partition.
Now I can see the size of the partition, but again it lists me 4 partition even if there is only one on the disk. And a mount is not working: "EXCEPTION: Could not mount partition"
I don't know how you make the USB. Can you download the Raspberry Pi image and burn to USB?
from sharpext4.
Related Issues (20)
- Exception when attempting to write text to file: "Could not read disk MBR." HOT 6
- Unhandled Exception while disposing ExtFileStream HOT 7
- Could not read disk MBR error HOT 9
- Could not mount partition error when read Flash Usb Ext4 HOT 1
- Error: Attempted to read or write protected memory. This is often an indication that other memory is corrupt. HOT 6
- (It can be simply modified to be compiled in Visual Studio 2013). How? HOT 4
- Error: Could not load file or assembly 'SharpExt4.dll' or one of its dependencies. The specified module could not be found. HOT 5
- Could not load file or assembly 'SharpExt4, Version=1.0.8402.18282 HOT 12
- How to read and write ext4 in vmdk HOT 4
- Unable to recognize EXT4 extended partition HOT 9
- Update Docs and cannot mount ext4 partition HOT 11
- Typo on ExtDisk "Partitions" getter HOT 1
- Add support for MBR disk type
- Open partition from a file system image? HOT 2
- en/decryption support? HOT 1
- Open multiple image HOT 11
- Could Not Read Disk MBR HOT 1
- GPT partition HOT 8
- ext4 for bootmgr.efi (Windows 7, 8, 10, 11) HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from sharpext4.