How to compress a file in rar as much as possible. Ways to compress a file as much as possible using WinRAR - settings, splitting into volumes. Data protection from unauthorized access

21.02.2024 external HDs

Instructions

When starting to archive files, make sure that the WinRAR application is installed on your computer. When choosing files to archive, remember that text format files are best compressed. Videos, music and images are reduced in size only slightly. To set the maximum compression size, in the archiver window, make the “General” tab active.

In the “Archive Format” group, find the “Compression Method” field. Using the drop-down list, set the value to “Maximum”, click on it with the left mouse button, and click on the OK button. The files will be compressed into an archive with the selected compression settings.

If necessary, you can access the compression settings and set your own values. To do this, in the archiver window, make the “Advanced” tab active and click on the “Compression Options” button in the “NTFS Options” group.

A new dialog box will open in which you can assign appropriate values ​​for text, audio and full-color graphics compression, select the main compression algorithm, and so on. If you are not sure that you have configured everything correctly, simply click on the “Default” button to restore the original values. To get more information about certain parameters, open the help desk by clicking on the “Help” button.

The actual addition of files to the archive is carried out as follows: select those files and folders that should be packed, right-click on the selection and select one of the “Add to archive” commands from the drop-down menu.

To add a new file to an existing archive and compress it as much as possible when packing, open the RAR file and select “Add file to archive” from the “Commands” menu or simply drag the icon of the desired file into the program window. A new Archive Name and Options dialog box will automatically open. Set the compression method to “Maximum” for the new file in the same way as described above. Click on the OK button.

Sources:

  • how to compress an archive

Windows has a built-in file compression feature. Compressed files take up less space on your hard drive and can be moved to another computer or hard drive partition faster than uncompressed files. Compressed files are also more convenient for sending via email. In order to compress a file or folder using built-in Windows tools, you only need to perform a few simple operations.

Instructions

Find the file or folder you want to compress. Right-click the file or folder, select Send to, and then select Compressed ZIP Folder.

Install the selected utility. If you decide to use separate archivers, restart your computer after installing the program. This is necessary to embed files into the operating system.

Create a new folder on your hard drive. Move or copy files into it that will be included in the archive. After preparing the information for compression, right-click on the icon of the desired directory.

In the menu that opens, select 7-Zip (WinRar). Wait for the new submenu to open and click on “Add to archive”. After some time, the archiver program window will launch.

Enter the name of the future file. If you plan to upload information to external resources, do not use Russian letters, spaces or punctuation marks. Select the archive format. Expand the “Compression level” column. Select "Maximum" or "Ultra".

Please remember that some resources have a limit on the maximum size of a single file. Fill out the “Split into volumes” field by entering the desired value. After preparing all the necessary parameters for creating an archive, click Ok.

Wait for the program to complete. The length of this process can vary greatly depending on the size of the source folder, the compression ratio chosen, and the type of files being processed.

If you included installation files for programs or utilities in the archive, extract them from the archive before installation. Archivers are not always able to gain full access to certain data stored in compressed form.

The Microsoft SQL Server database management system is one of the most flexible and powerful today. All data of the databases served by it are stored in mdf files (Master Database File). When the database is used intensively (multiple insertions and deletions of table rows), fragmentation of the container file occurs. Its volume begins to greatly exceed the actual amount of data stored in the database. If necessary, you can compress the mdf file using SQL Server.

You will need

  • - Microsoft SQL Server running on a local computer;
  • - SQL Server Management Studio.

Instructions

Connect to the database server. In SQL Server Management Studio, select "Connect Object Explorer..." from the File section of the main menu. The Connect to Server dialog appears. The same dialog appears automatically after starting SQL Server Management Studio. Select the Database Engine item from the Server type drop-down list. In the Server name text box, enter the local computer name. In the Authentication list, make the current item corresponding to the authentication type supported by the local SQL server. If you select SQL Server Authentication, enter valid credentials in the User name and Password fields. Click the Connect button.

Begin the process of adding an existing database. Select the Databases element in the Object Explorer panel. Right-click on it. Select "Attach..." from the context menu.

Select mdf file to attach. In the Attach Databases window dialog, click the "Add..." button. In the Select the file folder tree of the Locate Database Files dialog, find and expand the directory with the mdf file. Select it and click OK.

Add a new database contained in an mdf file. In the Attach Databases window, check that the path is specified correctly. Select a single item in the Databases to attach list. In the Database details control group, delete the item corresponding to the log file if it is not found (the message Not found is displayed in the Message field). To do this, click the Remove button. Click OK.

Dozens of archivers are popular on the Internet today, and in the description of each program you can find that its algorithm is the very best... I decided to take several popular archivers on the Internet, namely: WinRar, WinUha, WinZip, KGB archiver, 7Z and test them in “combat” » conditions.

A little preface... The comparison may not be very objective. The comparison of the ahivators was carried out on the most common home computer, the average for today. In addition, different types of data were not taken: the compression comparison was carried out on a regular “Word” document, of which many who study or work with them can accumulate a huge amount. Well, it is logical that it is advisable to pack information that you rarely use into an archive and sometimes extract it. And it’s much easier to transfer such a file: it will be copied to a flash drive faster than a bunch of small files, and it will be downloaded faster over the Internet...

Compression comparison table

For a small experiment, a relatively large RTF file was taken - about 3.5 MB and compressed with different archivers. We are not taking into account the operating time yet, the features of the programs will be discussed further, but now we will just look at the compression level.

Program Format Compression ratio Size, kbytes How many times has the file size decreased? ?
KGB Archiver 2.kgbmaximum141411 22,99
WinRar.rarmaximum190546 17,07
WinUha.uhamaximum214294 15,17
7Z.7zmaximum218511 14,88
WinZip.zipmaximum299108 10,87
Original file.rtfWithout compression3252107 1

As can be seen from the small plate, the highest compression ratio is achieved with the KGB Archiver 2 program - the original file size has decreased by 23 times! Those. if you have several gigabytes of various documentation on your hard drive that you don’t use and want to delete (but you can’t shake the feeling that it might come in handy) - wouldn’t it be easier to compress it with such a program and write it to disk...

But about all the pitfalls in order...

KGB Archiver 2

In general, it’s not a bad archiver; according to the developers, their compression algorithm is one of the “strongest”. It's hard to disagree...

Only the compression speed leaves much to be desired. For example, the file in the example (about 3 MB) was compressed by the program for about 3 minutes! It is not difficult to estimate that she will compress one CD disc for half a day, if not more.

But this is not particularly surprising. Unpacking a file takes as long as compression! Those. If you spent half a day compressing some of your documents, then you will spend the same amount of time getting them out of the archive.

Result: the program can be used for small amounts of information, especially when the minimum size of the source file is important (for example, the file needs to be placed on a floppy disk or on a small flash drive). But again, it is impossible to guess the size of the compressed file in advance, and you may waste time on compression...

WinRar

The famous program in the post-Soviet space is installed on most computers. Probably, if she had not shown such good results, she would not have had so many fans. Below is a screenshot showing the compression settings, nothing special, except that the compression level was set to maximum.

Surprisingly, WinRar compressed the file in a few seconds, and the file size was reduced by 17 times. a very worthy result, considering that the time spent on processing is negligible. And the time to unpack the file is even less!

Result: An excellent program that shows some of the best results. During the compression settings, you can also specify the maximum archive size and the program will split it into several parts. This is very convenient for transferring a file from one computer to another on a flash drive or CD/DVD disk, when you cannot write the entire file to...

WinUha

A relatively young archivist. It cannot be called super-popular, but many users who often work with archives have an interest in it. And it is no coincidence, because according to the developers of the archiver, its compression algorithm is stronger than that of RAR and 7Z.

In our small experiment, I would not say that this is so. It is possible that on some other data it will show much better results...

By the way, when installing, select English; in Russian, the program displays “cryakozabry”.

Result: a good program with an interesting compression algorithm. The time to process and create an archive is, of course, longer than WinRar, but for some types of data you can get a slightly higher compression ratio. Although, personally, I would not put much emphasis on this...

7Z

A very popular free archiver. Many argue that the compression ratio in 7z is even better than in WinRar. It’s quite possible, but when compressed with the “Ultra” level on most files, it loses to WinRar.

Result: a good alternative to WinRar. Quite comparable compression ratio, good support for the Russian language, convenient integration into the Explorer context menu.

WinZip

Legendary, one of the most popular archivers ever. On the Internet, probably the most common archives are “ZIP”. And it’s no coincidence - despite the not-so-high compression ratio, the speed of operation is simply amazing. For example, Windows opens such archives as regular folders!

In addition, we should not forget that this archiver and compression format is much older than its newfangled competitors. And not everyone now has powerful computers that will allow them to quickly work with new formats. And the Zip format is supported by all modern archivers!

Hello Habr!
This article is devoted to how to properly and maximally compress files into ZIP archives. I decided to write this article for the reason that many applications package their formats in ZIP. In this article, we will look at ZIP compression methods, ZIP compression applications, and how compression can be improved.

ZIP compression method

To begin with, I propose to understand that ZIP supports different compression methods (Copy, Deflate, Deflate64, BZip2, LZMA, PPMd), but we will consider only one compression method - Deflate, for the reason that this is the method that most applications use, which package their formats in ZIP. Here is a small list of file formats that are actually ZIP archives - open-file.ru (enter the ASCII header descriptor - PK in the search). Let me make a reservation right away: this is only a small list of files.

Deflate compression method

Today there are several libraries based on the Deflate compression method:
Deflate Library Operation speed Compression ratio Applications
Zlib High Low
7-zip Average Average 7-zip
Kzip Low High kzip
So before choosing an archiver for ZIP, we need to understand what result we need and how much time we are willing to spend to get it. Deflate is characterized by the higher the compression ratio, the more time it will take.

ZIP archivers

In this section, we will only consider those applications that are free to use.
7-zip algorithm
Here we will talk about two programs that implement the 7-zip algorithm: 7-zip and advzip.
When creating a zip archive using 7-zip, I use the following parameters

R -mm=Deflate -y -tzip -mpass=15 -mfb=258 -mx9
The peculiarity of advzip is that it already works with ready-made zip archives, i.e. you simply specify the path to the archive, and it itself tries to compress it. It can be convenient when you already have a ready-made archive, and you don’t need to unpack and archive again.

kzip algorithm
The kzip algorithm was implemented in the kzip application, the application is extremely slow, but almost always gives the best result. It has settings (/s, /n, /b) that can improve/worse the ZIP compression ratio. Here I wanted to give some recommendations on how to get the best compression ratio (recommendations are based on personal experience):
  • If you are archiving files and there are ZIP archives, I recommend decompressing these archives (for convenience, you can use advzip with the /z0 parameter). This is because the Deflate method does not support continuous archives, i.e. It turns out that when the Deflate method tries to compress a decompressed archive, the decompressed archive in this case appears as one whole file and its contents are compressed as a continuous archive.
  • If you want to get the maximum compression effect, you can use the zipmix application. Let's say you created two zip archives with the same content using kzip, but with different settings, and as a result you received archives of different sizes. But this does not mean that all the files that you compressed in the first archive are individually smaller in compressed form than in the second archive. For these purposes you need zipmix; it creates a third archive from two archives, with a smaller size, because it compares each file individually and selects the one with the smaller size. zipmix works not only with kzip archives.

Practice

And so I decided to show how it all works. For example, I took the game for iPad - Angry Birds HD version 2.0.0. The original game size is 13,547,363 bytes.

As you can see, zipmix can't improve the compression ratio much. Personally, when I need to get the maximum, I simply combine all three (kzip + advzip + 7-zip) results into one. This is much better than trying to sort through the parameters in kzip.

Archiving files is a process that allows you to reduce the size of files and, accordingly, the space they occupy on disk. Archiving is often used on the Internet, since not everyone can download large amounts of data. And there is no need, because unpacking takes a tiny amount of time compared to the time of downloading an uncompressed file. Archivers are also often used when they want to make a container for files. That is, a large number of files are packed into one convenient file.

You need to remember that text files and programs are best packaged. Music, video, and picture files are poorly archived.

There are many archivers, the most common of which are ZIP and RAR. In recent versions of Windows, a ZIP archiver is built into the system. But many files are packed with the RAR archiver. The version for RAR for Windows is called WinRAR. Let's study the process of archiving and unarchiving.

The WinRAR program is very simple and does not require any special settings. That is, it works on the principle “Install - Work” or, as they also say, “works out of the box”. Let's try to compress something. For example, the Temp folder on drive D:. Open WinRar:

Select the desired file or folder (in our case, the Temp folder) and click the “Add” button, we will get an archive settings dialog:


Change the archive name to your liking in the corresponding first paragraph.

If you want to change the compression level, select the desired one in the “Compression Method” drop-down menu. The default is Normal. If you are archiving poorly compressed files, it is better to choose the compression method: “No compression” to save time. The maximum method is not recommended unless you need to reduce the size to the maximum at all costs.

Also, if you want to archive your files and put it on floppy disks, you can select “Split into volumes by size” in the drop-down menu and select “Auto-detection”.

If you want your file to be able to be unzipped (unzipped) by anyone, even if you don’t have WinRAR installed on your computer, then check the box next to “Create SFX archive.” self extractable- self-extracting). The program will create an .exe file that can be run on any computer running the Windows operating system.

After making all changes, click OK and the program will begin archiving your files. The program places the archive file in the same folder where the archived files are located.

Now let's move on to unzipping (unpacking) the files.

In WinRAR, find the archive file that needs to be unpacked and click the “Extract” button, the following dialog will appear.

I think each of us has more than once encountered the need to send a large file, say, by email, or dump it on an external drive. I will definitely not open America for anyone if I say that this can be done thanks to existing archivers, in particular, WinRar, which we will talk about today. However, not everyone knows about the various nuances that will help answer the question more efficiently and quickly: “how to compress in winrar?”

Archiving files using WinRar

The WinRar program is very simple, even a novice user can use it, everything in it is accessible and intuitive. The first thing you need to do is download the archiver on the Internet and then install it. Next, select the required file, say, we need to compress the folder in winrar. Right-click on it and look for the line “Add to archive.”

After this, a window automatically opens in which you need to select archiving parameters, archive format, etc., in principle, there is no need to change anything, you can leave it as is.

Please note that if you want to create an archive consisting of many parts (volumes), then at the very bottom, in the “Divide into volumes by size (in bytes)” column, you need to put the required number. If you need one file, then leave this line blank.

One more nuance: in the rar format the file is compressed more strongly than in the zip format, which means it takes longer.

You can also set your own compression options using the Advanced tab. In it you will find the “Compression Options” button, and then select by tick what you need, for example, compression algorithm, compression of full graphics, etc.

Data protection from unauthorized access It is noteworthy that, if necessary, you can protect the archived file from attacks.

So, it is possible, without the correct indication of which there will be no unzipping. To do this, in the same settings window, go to the “Advanced” tab. There is a button “Set password”, click and enter the desired password. If you do not want to adjust any more parameters, click “OK”, thereby starting the archiving process.

Well, that’s all, I think that we have figured out the question “how to compress a file in winrar”. But the question of how to extract files from a WinRar archive is described in this . All this knowledge will allow you to significantly save space on your computer or external media, as well as transfer large files on the Internet. From now on, compressing a video in winrar or any other file is not a problem for you at all.