Difference between revisions of "Pinebook Pro"
Jump to navigation
Jump to search
Petaramesh (talk | contribs) |
CameronNemo (talk | contribs) (Improve grammar. Also systemd services do not need to be made executable.) |
||
Line 589: | Line 589: | ||
$ sudo nvme set-feature /dev/nvme0 -f 2 -v 2 -s | $ sudo nvme set-feature /dev/nvme0 -f 2 -v 2 -s | ||
set-feature:02 (Power Management), value:0x000002</pre> | set-feature:02 (Power Management), value:0x000002</pre> | ||
Some NVMe SSDs don't appear to allow saving the setting with "-s" option. In those cases, leave off the "-s" and use a startup script to set the non-default power state at boot.<br> | Some NVMe SSDs don't appear to allow saving the setting with "-s" option. In those cases, leave off the "-s" and use a startup script to set the non-default power state at boot.<br> | ||
If you want to test performance without saving the new power setting semi-permanantly, then leave off the "-s" option.<br/> | If you want to test performance without saving the new power setting semi-permanantly, then leave off the "-s" option.<br/> | ||
<br/> | <br/> | ||
On Manjaro, | |||
On systemd based distros like Manjaro, a non-defaut power state for an NVME can be set using a systemd service. This is useful in cases where the NVME drive does not save the power state and/or uses APST. | |||
<pre>[Unit] | |||
An example systemd service, nvme-throttle.service, is shown below: | |||
<pre> | |||
[Unit] | |||
Description=Throttles NVME to lesss power hungry mode | Description=Throttles NVME to lesss power hungry mode | ||
After=suspend.target hibernate.target hybrid-sleep.target suspend-then-hibernate.target | After=suspend.target hibernate.target hybrid-sleep.target suspend-then-hibernate.target | ||
Line 603: | Line 608: | ||
[Install] | [Install] | ||
WantedBy=multi-user.target suspend.target hibernate.target hybrid-sleep.target suspend-then-hibernate.target</pre> | WantedBy=multi-user.target suspend.target hibernate.target hybrid-sleep.target suspend-then-hibernate.target | ||
</pre> | |||
Here the value after "-v" is the maximum power state that you want your SSD to use.<br/> | Here the value after "-v" is the maximum power state that you want your SSD to use.<br/> | ||
<br/> | <br/> | ||
This will be executed at system startup, and every time your system exits any suspend mode that might reset the SSD to default values.<br/><br/> | This will be executed at system startup, and every time your system exits any suspend mode that might reset the SSD to default values.<br/><br/> | ||
<pre>systemctl daemon-reload | This file needs to be placed in the /etc/systemd/system directory. Afterwards, to activate the service, run: <br/> | ||
systemctl enable --now nvme-throttle.service</pre> | |||
<pre> | |||
systemctl daemon-reload | |||
systemctl enable --now nvme-throttle.service | |||
</pre> | |||
<br/> | <br/> |