473,785 Members | 2,391 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

How can I zip a 8 Gb file using c# ?

I need to zip up an 8Gb file using C# - do you know of any freeware libraries
I can use to accomplish this? I guess it needs to be Zip64 to support such
file sizes.

I tried something called sharpziplib but it doesn't support >2Gb files -
they are working on it however but I cannot wait...
Oct 2 '06 #1
11 12149
Hello, MrNobody!

MI need to zip up an 8Gb file using C# - do you know of any freeware
Mlibraries
MI can use to accomplish this? I guess it needs to be Zip64 to support
Msuch
Mfile sizes.

MI tried something called sharpziplib but it doesn't support >2Gb
Mfiles -
Mthey are working on it however but I cannot wait...

Did you try GZipStream?
( http://msdn2.microsoft.com/en-us/lib...zipstream.aspx )
You must be using .NET 2.0 to work with it.

--
Regards, Vadym Stetsyak
www: http://vadmyst.blogspot.com
Oct 2 '06 #2


"Vadym Stetsyak" wrote:
Hello, MrNobody!

MI need to zip up an 8Gb file using C# - do you know of any freeware
Mlibraries
MI can use to accomplish this? I guess it needs to be Zip64 to support
Msuch
Mfile sizes.

MI tried something called sharpziplib but it doesn't support >2Gb
Mfiles -
Mthey are working on it however but I cannot wait...

Did you try GZipStream?
( http://msdn2.microsoft.com/en-us/lib...zipstream.aspx )
You must be using .NET 2.0 to work with it.

--
Regards, Vadym Stetsyak
www: http://vadmyst.blogspot
Looks like GZip wouldn't work either, from the 'Remarks' :

"This class cannot be used to compress files larger than 4 GB."
Oct 2 '06 #3
MrNobody <Mr******@discu ssions.microsof t.comwrote:
>

"Vadym Stetsyak" wrote:
>Hello, MrNobody!

MI need to zip up an 8Gb file using C# - do you know of any freeware
Mlibraries
MI can use to accomplish this? I guess it needs to be Zip64 to support
Msuch
Mfile sizes.

MI tried something called sharpziplib but it doesn't support >2Gb
Mfiles -
Mthey are working on it however but I cannot wait...

Did you try GZipStream?
( http://msdn2.microsoft.com/en-us/lib...zipstream.aspx )
You must be using .NET 2.0 to work with it.

--
Regards, Vadym Stetsyak
www: http://vadmyst.blogspot

Looks like GZip wouldn't work either, from the 'Remarks' :

"This class cannot be used to compress files larger than 4 GB."
4GB is the maximum addressible size for a 32-bit pointer. Also, GZIP is not
the same as ZIP, so if you need PKZIP compatibility, then you need to get
another library.

--
Thomas T. Veldhouse
Key Fingerprint: 2DB9 813F F510 82C2 E1AE 34D0 D69D 1EDC D5EC AED1
Oct 2 '06 #4

"MrNobody" <Mr******@discu ssions.microsof t.comwrote in message
news:E0******** *************** ***********@mic rosoft.com...
|
|
| "Vadym Stetsyak" wrote:
|
| Hello, MrNobody!
| >
| MI need to zip up an 8Gb file using C# - do you know of any freeware
| Mlibraries
| MI can use to accomplish this? I guess it needs to be Zip64 to support
| Msuch
| Mfile sizes.
| >
| MI tried something called sharpziplib but it doesn't support >2Gb
| Mfiles -
| Mthey are working on it however but I cannot wait...
| >
| Did you try GZipStream?
| (
http://msdn2.microsoft.com/en-us/lib...zipstream.aspx )
| You must be using .NET 2.0 to work with it.
| >
| --
| Regards, Vadym Stetsyak
| www: http://vadmyst.blogspot
|
| Looks like GZip wouldn't work either, from the 'Remarks' :
|
| "This class cannot be used to compress files larger than 4 GB."

Which is wrong too, actually the limit is 2GB, that's the max.size of an
object in .NET and the GZIP library needs the complete file to be read in a
single byte array (which obviously is limitted to 2GB).

Willy.
Oct 2 '06 #5
OK guys, found someone who made a modification to the sharpziplib out there
to support Zip64 and it works. Compressed my 7.6 Gb file and then used Winzip
to uncompress it. Works good !

thanks for your time trying to help me :)
Oct 2 '06 #6
Would you like to share the name/web address of "someone". Might be useful
to know.

Steve
"MrNobody" <Mr******@discu ssions.microsof t.comwrote in message
news:D2******** *************** ***********@mic rosoft.com...
OK guys, found someone who made a modification to the sharpziplib out
there
to support Zip64 and it works. Compressed my 7.6 Gb file and then used
Winzip
to uncompress it. Works good !

thanks for your time trying to help me :)

Oct 3 '06 #7
http://www.icsharpcode.net/OpenSourc.../Download.aspx

Nirosh

"Steve Barnett" <no****@nodomai n.comwrote in message
news:u4******** ******@TK2MSFTN GP02.phx.gbl...
Would you like to share the name/web address of "someone". Might be useful
to know.

Steve
"MrNobody" <Mr******@discu ssions.microsof t.comwrote in message
news:D2******** *************** ***********@mic rosoft.com...
>OK guys, found someone who made a modification to the sharpziplib out
there
to support Zip64 and it works. Compressed my 7.6 Gb file and then used
Winzip
to uncompress it. Works good !

thanks for your time trying to help me :)


Oct 3 '06 #8
Isn't that the original source. I was interested in the Zip64 variant.

Steve

"Champika Nirosh" <te**@tc.comwro te in message
news:uW******** ******@TK2MSFTN GP06.phx.gbl...
http://www.icsharpcode.net/OpenSourc.../Download.aspx

Nirosh

"Steve Barnett" <no****@nodomai n.comwrote in message
news:u4******** ******@TK2MSFTN GP02.phx.gbl...
>Would you like to share the name/web address of "someone". Might be
useful to know.

Steve
"MrNobody" <Mr******@discu ssions.microsof t.comwrote in message
news:D2******* *************** ************@mi crosoft.com...
>>OK guys, found someone who made a modification to the sharpziplib out
there
to support Zip64 and it works. Compressed my 7.6 Gb file and then used
Winzip
to uncompress it. Works good !

thanks for your time trying to help me :)



Oct 3 '06 #9
Willy Denoyette [MVP] <wi************ *@telenet.bewro te:
>
"MrNobody" <Mr******@discu ssions.microsof t.comwrote in message
news:E0******** *************** ***********@mic rosoft.com...
|
|
| "Vadym Stetsyak" wrote:
|
| Hello, MrNobody!
| >
| MI need to zip up an 8Gb file using C# - do you know of any freeware
| Mlibraries
| MI can use to accomplish this? I guess it needs to be Zip64 to support
| Msuch
| Mfile sizes.
| >
| MI tried something called sharpziplib but it doesn't support >2Gb
| Mfiles -
| Mthey are working on it however but I cannot wait...
| >
| Did you try GZipStream?
| (
http://msdn2.microsoft.com/en-us/lib...zipstream.aspx )
| You must be using .NET 2.0 to work with it.
| >
| --
| Regards, Vadym Stetsyak
| www: http://vadmyst.blogspot
|
| Looks like GZip wouldn't work either, from the 'Remarks' :
|
| "This class cannot be used to compress files larger than 4 GB."

Which is wrong too, actually the limit is 2GB, that's the max.size of an
object in .NET and the GZIP library needs the complete file to be read in a
single byte array (which obviously is limitted to 2GB).
Why does GZIP require the entire file to be in memory first? It is a sliding
window algorithm similar to LZW. In any case, implementation is via a
GZIPStream, which doesn't seem to require the entire file be loaded into
memory first, so I believe 4GB is indeed the limit (which is the limit of
addressable memory with a 32-bit pointer).

--
Thomas T. Veldhouse
Key Fingerprint: 2DB9 813F F510 82C2 E1AE 34D0 D69D 1EDC D5EC AED1
Oct 3 '06 #10

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

8
4068
by: Eric Lilja | last post by:
Hello, I had what I thought was normal text-file and I needed to locate a string matching a certain pattern in that file and, if found, replace that string. I thought this would be simple but I had problems getting my algorithm to work and in order to help me find the solution I decided to print each line to screen as I read them. Then, to my surprise, I noticed that there was a space between every character as I outputted the lines to the...
3
26269
by: StGo | last post by:
How can i read/write file's custom attributs(like subject,author...) in C#??? Thanks :))
9
8277
by: ALI-R | last post by:
Hi,, I have two questions : 1) Is it mandatory that config file of a desktop application must be App.config 2) Is it possible to update config file in your code?? thanks for your help. ALI
13
4323
by: Sky Sigal | last post by:
I have created an IHttpHandler that waits for uploads as attachments for a webmail interface, and saves it to a directory that is defined in config.xml. My question is the following: assuming that this is suppossed to end up as a component for others to use, and therefore I do NOT have access to their global.cs::Session_End() how do I cleanup files that were uploaded -- but obviously left stranded when the users aborted/gave up writting...
15
4779
by: Nathan | last post by:
I have an aspx page with a data grid, some textboxes, and an update button. This page also has one html input element with type=file (not inside the data grid and runat=server). The update button will verify the information that has been entered and updates the data base if the data is correct. Update will throw an exception if the data is not validate based on some given rules. I also have a custom error handling page to show the...
1
19965
by: ABCL | last post by:
Hi All, I am working on the situation where 2 different Process/Application(.net) tries to open file at the same time....Or one process is updating the file and another process tries to access it, it throws an exception. How to solave this problem? So second process can wait until first process completes its processing on the file. Thanks in advance
1
1879
by: Jerry John | last post by:
I am working in ASP.NET with C#. I have a text file which contains datas with delimiters. For example:- MSH|^~\$|DISCHARGE|CLAY COUNTY MEMORIAL|||200502110939| I also have an XML file created with predefined tags. Some of the tags contain child element. I need to pass the data from the text file i.e the value within the delimiters should be passed to the corresponding tags within the XML file. I have done this through hard code. But i...
1
6509
by: laredotornado | last post by:
Hi, I'm using PHP 4.4.4 on Apache 2 on Fedora Core 5. PHP was installed using Apache's apxs and the php library was installed to /usr/local/php. However, when I set my "error_reporting" setting to be "E_ALL", notices are still not getting reported. The perms on my file are 664, with owner root and group root. The php.ini file is located at /usr/local/lib/php/php.ini. Any ideas why the setting does not seem to be having an effect? ...
9
8392
by: JimmyKoolPantz | last post by:
IDE: Visual Studio 2005 Language: VB.NET Fox Pro Driver Version: 9.0.0.3504 Problem: I currently have a problem altering a DBF file. I do not get any syntax errors when running the program. However, after I alter the table and open microsoft excel to look at any changes; I get the following error: "This file is not in a recognizable format" If I do open the file in excel it looks like its not formatted.
3
8299
by: JDeats | last post by:
I have some .NET 1.1 code that utilizes this technique for encrypting and decrypting a file. http://support.microsoft.com/kb/307010 In .NET 2.0 this approach is not fully supported (a .NET 2.0 build with these methods, will appear to encrypt and decrypt, but the resulting decrypted file will be corrupted. I tried encrypting a .bmp file and then decrypting, the resulting decrypted file under .NET 2.0 is garbage, the .NET 1.1 build works...
0
9645
marktang
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
1
10091
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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8972
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
6740
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 then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5381
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5511
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4053
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3646
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2879
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.