SPO5
.pdf1
! " " # $ "" %" % & ' (
" "$' " )-+ , " ' !
. .
2011
2
621.3.037.3 (075)
. . ! ": !. -
% / . . . - ' ( ')*+, 2011. - 87 .
. / 0 / " % 1 ( / ( 0 ( ! -
02 ! % % « ! "».
5 ! 06 % / 1 " / ( %/ " 6 7 0 !%" ( 8 9 2302001 – «* 7 8 0 - 0 2» " 6 1 " 6 7 !%" (
; 8 1 0: _____________________________
_____________________________
|
3 |
Оглавление |
|
'................................................................................................................. |
6 |
1. , .1. / 01 2 2 3 4 2 5 3 622
37 8 |
................................................................................................................. |
8 |
|
1.1. = 9 ......................................................................................! 0 |
8 |
||
1.2. + " ........................................................................( " 9 |
8 |
||
1.2.1. ....................................................................... |
+ 0 / 02 |
12 |
|
1.2.2. .............................. |
. %" 7 8 / |
14 |
|
1.2.3. .... |
. %" 7 8 ! / / |
15 |
|
1.2.4. ....... |
. %" 7 8 ! 8 6 |
16 |
|
1.2.5. ...................... |
. %" / 02 %? 6 / |
17 |
|
1.3. . |
%" ...............................................7 8 ( |
17 |
|
1.4. @ / ................................................! %A ! % |
18 |
||
2. , ..........2. / 2 5 7 3. 1 |
19 |
||
2.1. = ..........................................................! 6 ! 0 |
19 |
||
2.2. C 0 .........................../ ( / 2 7 6 |
19 |
||
2.3. / D .......................................................................! 0 |
26 |
||
2.4. . |
(/ .......................................................0 ( ! 0 |
26 |
|
2.5. + ! ...............................................( / D A " |
26 |
||
3. , ..........3. / 2 5 7 3. 2 |
27 |
||
3.1. = 9 ...........................................................! 6 ! 0 |
27 |
||
3.2. + " ......................................................................( " 9 |
27 |
||
3.3. . |
(/ .......................................................0 ( ! 0 |
35 |
|
3.4. + ! ...............................................( / D A " |
35 |
4. , .4 "2 21 24 > ?12 3 4
2 ........................................................................................................................ |
|
37 |
4.1. = 9 ! 0.................................................................................... |
37 |
|
4.2. + " ( " 9...................................................................... |
37 |
|
4.2.1. |
.( %............................................................... |
38 |
4.2.2. |
" 6 1! ......................................... |
39 |
4.3. 0 1 / 6.......................................................................... |
43 |
4 |
|
4.4. E / 0 ( ! 0 ............................................................... |
44 |
4.5. / D " ........................................................................ |
44 |
4.6. 9 0 0................................................................... |
45 |
5. , .5. $7 2 7 6 32 " |
|
Windows..................................................................................................................... |
46 |
5.1. = 9 ! 0.................................................................................... |
46 |
5.2. + " ( " 9...................................................................... |
46 |
5.3. 0 1 / 6.......................................................................... |
51 |
5.4. E / 0 ( ! 0 ............................................................... |
56 |
5.5. / D " ........................................................................ |
56 |
5.6. 9 0 0................................................................... |
56 |
6. , .6. " 2 3 H 7 1 ?I 7 2 J 24
" Windows....................................................................................................... |
57 |
|
6.1. = 9 ! 0.................................................................................... |
57 |
|
6.2. + " ( " 9...................................................................... |
57 |
|
6.5. 0 1 / 6.......................................................................... |
63 |
|
6.6. E / 0 ( ! 0 ............................................................... |
63 |
|
6.7. / D " ........................................................................ |
64 |
|
6.8. 9 0 0................................................................... |
64 |
|
7. , .7. ! I 2 3? 2 I 2 622............... |
65 |
|
7.1. = 9 ! 0.................................................................................... |
65 |
|
7.2. + " ( " 9...................................................................... |
65 |
|
8. , .8. / H 2 0 |
|
|
7 62 4 2 3?........................................................................................... |
66 |
|
8.1. F 6 BIOS............................................................................. |
66 |
|
2.1. % 9 ( K VMware Workstation ................................ |
69 |
|
2.2. ./ / % 9 6 K 0 / ( % |
|
|
8 6 0. ....................................................................... |
79 |
|
2.2.1. |
/ 1/ D / . .............................. |
80 |
2.2.2. |
1/ " (primary) 1/ ........................... |
81 |
2.2.3. |
1/ " 2 /............................................. |
84 |
3. , .6. $ Windows XP....................... |
87 |
|
5 |
|
1.1 |
+ 06 D % Windows XP ................................. |
87 |
1.2 |
) 7 " 6 D % Windows XP ............................. |
88 |
4. , .7. / H 2 3 H 2 |
|
|
28 >....................................................................................................... |
96 |
|
4.1. |
.? TEMP TMP 9 " / |
|
D: |
96 |
|
4.2. |
.? «b / % 0» / D: .................. |
97 |
4.3. / / D Windows\Driver Cache\i386\ |
|
|
Windows\system32\dllcache\ ................................................................. |
99 |
|
4.4. |
. D / " K !......................... |
100 |
4.5. |
7 8 ( D / ............................................... |
100 |
4.6. |
C A" ( 0 ...................................... |
101 |
5., .8. " 2 > 2 3 H 2. 103
6., .9. 2 2 > 0 2
37 8............................................................................................................. |
117 |
6.1. + D / .................................................... |
117 |
6.2. + ( .................................................................. |
119 |
"/ " "/ ,M# % ! '$! % ,$N
121
6
'
> 2 J 28 2 5 3 28 1.
C " ! 6 ! 0 ( ( 2 7 2102297 . 6 0 / D !0 9 K-
6 25 , 6 – 15 , 2% – 20 , 1% – 25 . - 80 ( 9 6 1 % %A ( 2% / . + " ! ( 91 K 7 Times New Roman Cyr 1 12 ., 0 – K 80. b D " 06 – / 06. !1 8 06 % – ( 9 " - 02 1 (1,27 .). @ / ( 9 2% 1%
/ % ( D " 0 .
( 91% ( K 06 K 7
Courier New 1 12 .
( %" ( " 9 1 " , " 0 ! - 0 ! / D 0 !0 9 ! KA 0 / / %. C! - 1 8 % 9 " / ( D.
( / " 1 " %/ / D 9 " ! 6
!, 06 / 06 1 % % ( 06 /% 9
0.
C " / D / D 9 1% 9 0 02 " /- D/ A? 2 9 9 ! 0 0.
> 2 5 3 28 7 H 33 ?I 7 0.
0 K% ( / Visual Studio 2008 (10
C++.
. 0 !D A ( / " 0 " -
!2 / 02 / ( ( % ( / /
6 10 / ). F !2 / D
7
9 /%, " i / D 0 % 9 9
" % 9 / / ( 1 ? * ( / D D 9 % 9 K 6 1 / ".
D/ ( !D ( / 0 (, (- (A? 1 " / D ? / ( ! . .
/ ! 6 / % 8:
////////////////////////////////////////////////////////
//1.
//: " ".
//! "# # . $.
//% " -201.
////////////////////////////////////////////////////////
8
1., .1. / 01 2 2 3 4 2 5 3 622 37 8.
1.1.( > ?
= 9A ! 6 ! 0 ( ( ( 1 0
6K 7% 8 ( VC++, 1 (A? %" 9 %A
7 8 A ! k b.
1.2.21 1
/ 6 ! 6 ! 0 K %, 0-
/(?%A i 7 6 / 0:
1)8 6 0;
2)2 /;
3)! / 2 " 2 / 2
4)/ 0 (;
5)/ 0 %? 6 /
F ( / D D / / 06
1.1:
,2 2 H 1.1. m / 0, 0 /(? 6 i -
%A %A 7 8 A ! k b.
#include "stdafx.h" #include <iostream>
#include <fstream> // ! ofstream #include <cstringt.h>
#include <locale.h>
//= > =?
//! ?
void HardDriveComputer(std::ofstream *file); // OS
BOOL SystemVersion(std::ofstream *file); //
9
void MemmoryStat(std::ofstream *file);
// P ! void CurrentDir(std::ofstream *file);
using namespace std;
/////////////////////////////////////////////////////////////
// % #
int _tmain(int argc, _TCHAR* argv[])
{
char szNameFile[_MAX_PATH] = "MyFile.txt";
setlocale(LC_CTYPE, "Russian_Russia.1251");
//>! b file ! > ! =? #
//szNameFile
ofstream file(szNameFile);
//c
SystemVersion(&file);
//! ?
HardDriveComputer(&file);
MemmoryStat(&file);
//P !
CurrentDir(&file);
file.close();
cout << "\nf = > = # #= : " << szNameFile << endl;
cout << "c - # g\n"; system("pause");
return 0;
}
//////////////////////////////////////////////////////////////////
// ! ?
void HardDriveComputer(std::ofstream *file)
{
char szFullDisk[20]; char cLetterOfDisk; BOOL bFlag;
UINT uTypD;
char szTypD[100];
//# ! # !
__int64 nFreeSpace;
//o # #
DWORD dwBytesPerSector;
10
//o # # #
DWORD dwSectorsPerCluster;
//o # # ! =? #
DWORD dwNumberOfFreeClusters; DWORD dwTotalNumberOfClusters;
for(cLetterOfDisk='A'; cLetterOfDisk<='Z'; cLetterOfDisk++)
{
sprintf_s(szFullDisk, sizeof(szFullDisk)-1, "%c:", cLetterOfDisk);
uTypD = GetDriveType(szFullDisk); switch (uTypD)
{
case DRIVE_UNKNOWN:
sprintf_s(szTypD, sizeof(szTypD)-1, "%s", " Unknown Drive\n");
break;
//xfy z fc {y| }~ z c$y•y| ocf ! =?
//# ! #.
}
bFlag = GetDiskFreeSpace(szFullDisk, &dwSectorsPerCluster, &dwBytesPerSector, &dwNumberOfFreeClusters, &dwTotalNumberOfClusters );
if(!bFlag) continue;
//o # # ! • ! # ?
nFreeSpace = __int64(dwNumberOfFreeClusters)* dwSectorsPerCluster*dwBytesPerSector;
//x =# #
*file << "\nDisk: " << cLetterOfDisk << szTypD << "=====================================\n";
//xfy z fc {y| }~ z c$y•y| ocf ! #=# !
//! # .
//‚=# ! ƒ
cout << "\nDisk: " << cLetterOfDisk << szTypD << "=====================================\n";
//xfy z fc {y| }~ z c$y•y| ocf ! #=# !
//! ƒ .
}
}
//////////////////////////////////////////////////////////////////
// # c
BOOL SystemVersion(std::ofstream *file)
{
OSVERSIONINFOEX osvi;