Windows 10: PageFile.sys batch script

Discus and support PageFile.sys batch script in Windows 10 Virtualization to solve the problem; Hello, I need help writing a batch script that would configure Windows Virtual Memory based on the amount of RAM installed If you have 4 GB of RAM,... Discussion in 'Windows 10 Virtualization' started by kamiloxf, Mar 4, 2021.

  1. kamiloxf Win User

    PageFile.sys batch script


    Hello,
    I need help writing a batch script that would configure Windows Virtual Memory based on the amount of RAM installed

    If you have 4 GB of RAM, set virtual memory to 8 GB (Custom size: set both initial and maximum size to 8192)
    If you have 8 GB of RAM, set virtual memory to 16 GB (Custom size: set both initial and maximum size to 16384).
    If you have 16 GB of RAM, set virtual memory also to 16 GB (Custom size: set both initial and maximum size to 16384)
    If you have 32 GB of RAM, set virtual memory also to 8 GB (Custom size: set both initial and maximum size to 8192) just in case.

    This virtual memory setting forces specific software on many computers

    Thank you very much for help

    :)
     
    kamiloxf, Mar 4, 2021
    #1

  2. C: pagefile .sys Degrag

    How do I defrag my C: pagefile .sys my O&O Degrag Prof states that the files is 32G with a 97.71 degree of relative fragmentation?
     
    WilliamHall9, Mar 4, 2021
    #2
  3. yegorsw Win User
    Run the audio troubleshooter from a batch script

    I have an automated home theatre setup - a batch script that enables my TV as a display, and changes the TV to be my primary display (so games and apps open on my TV instead of my monitor).

    The same script also changes my default audio device to be the TV.

    The problem is every time I turn off my TV, it disappears from the list of audio output devices in Windows 10, and even when I turn it back on, it does not appear in the list. However, if I RIGHT CLICK on the audio icon and select "troubleshoot sound problems"
    and immediately cancel/close the troubleshooter, the TV is automagically added to my list of output devices.

    My question is - is there any way to have this troubleshooter be launched from a batch script and instantly closed? Alternatively, is there a way to force a refresh of the audio devices through a batch script?
     
    yegorsw, Mar 4, 2021
    #3
  4. PageFile.sys batch script

    Clear Pagefile on Shutdown


    I've been looking into clearing the pagefile, and I found the following steps at a somewhat dated webpage:
    1. In the registry editor, navigate to: HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Memory Management
    2. Set ClearPageFileAtShutdown to the REG_DWORD value of 1.
    3. Restart Windows.
    I'm just wondering whether those steps are still valid, and, if so, does clearing the pagefile work as advertised?
     
    gregyurkon, Mar 4, 2021
    #4
Thema:

PageFile.sys batch script

Loading...
  1. PageFile.sys batch script - Similar Threads - PageFile sys batch

  2. pagefile sys

    in Windows 10 Network and Sharing
    pagefile sys: hi my pagefile sys went up suddenly to 11 gb while was playing game and after like end match in game it went back to normal how it was before it maked first time i think is it normal...
  3. pagefile sys

    in Windows 10 Gaming
    pagefile sys: hi my pagefile sys went up suddenly to 11 gb while was playing game and after like end match in game it went back to normal how it was before it maked first time i think is it normal...
  4. pagefile sys

    in Windows 10 Software and Apps
    pagefile sys: hi my pagefile sys went up suddenly to 11 gb while was playing game and after like end match in game it went back to normal how it was before it maked first time i think is it normal...
  5. Batch scripting

    in Windows 10 Software and Apps
    Batch scripting: Hi, here's the code that I used for 3 DISM commands to start automatically after pressing a key:Code and result:Code:@echo off echo You are going to use DISM. echo 1. To check the image. echo 2. Scan your PC's health echo 3. Restore your PC'S health. echo To continue, press...
  6. Batch scripting

    in Windows 10 Gaming
    Batch scripting: Hi, here's the code that I used for 3 DISM commands to start automatically after pressing a key:Code and result:Code:@echo off echo You are going to use DISM. echo 1. To check the image. echo 2. Scan your PC's health echo 3. Restore your PC'S health. echo To continue, press...
  7. Batch scripting

    in Windows 10 Network and Sharing
    Batch scripting: Hi, here's the code that I used for 3 DISM commands to start automatically after pressing a key:@echo off echo You are going to use DISM. echo 1. To check the image. echo 2. Scan your PC's health echo 3. Restore your PC'S health. echo To continue, press any key. echo Before...
  8. Batch Scripts / Programs.

    in Windows 10 Performance & Maintenance
    Batch Scripts / Programs.: The members and quests who use this forum know how professional, informative and helpful it is! In order to help members solve their problems/issues we often ask them to run certain programs and perform certain tasks and then upload [ post ] the results to the forum for us...
  9. C: pagefile .sys Degrag

    in Windows 10 Network and Sharing
    C: pagefile .sys Degrag: How do I defrag my C: pagefile .sys my O&O Degrag Prof states that the files is 32G with a 97.71 degree of relative fragmentation? https://answers.microsoft.com/en-us/windows/forum/all/c-pagefile-sys-degrag/1435a24e-30c1-43a8-9587-dbbac2c1216e"
  10. Batch script question

    in Windows 10 Support
    Batch script question: Hello, I want make a batch script to delete a spefic folder on the C disk, but how can I get only that spefic folder? I got this: Code: FOR /D %%p IN ("C:\USERS\%USERNAME%\Downloads\*.*") DO rmdir "%%p" /s /q cd C:\USERS\%USERNAME%\Downloads\ del *.* /q /s timeout /t 5...