https://wiki.archlinux.org/api.php?action=feedcontributions&user=Mackncheesiest&feedformat=atomArchWiki - User contributions [en]2024-03-29T12:57:48ZUser contributionsMediaWiki 1.41.0https://wiki.archlinux.org/index.php?title=BOINC&diff=776389BOINC2023-04-25T21:07:24Z<p>Mackncheesiest: Add small caveat to the syslog spam solution</p>
<hr />
<div>[[Category:Volunteer computing]]<br />
[[de:BOINC]]<br />
[[ja:BOINC]]<br />
[[zh-hans:BOINC]]<br />
From the [https://boinc.berkeley.edu/ BOINC website]:<br />
<br />
:Use the idle time on your computer (Windows, Mac, or Linux) to cure diseases, study global warming, discover pulsars, and do many other types of scientific research. It's safe, secure, and easy.<br />
<br />
From [[Wikipedia:BOINC]]:<br />
:The Berkeley Open Infrastructure for Network Computing (BOINC) is a non-commercial middleware system for volunteer and grid computing. It was originally developed to support the SETI@home project before it became useful as a platform for other distributed applications in areas as diverse as mathematics, medicine, molecular biology, climatology, and astrophysics. The intent of BOINC is to make it possible for researchers to tap into the enormous processing power of personal computers around the world.<br />
<br />
== Installation ==<br />
<br />
[[Install]] either the {{Pkg|boinc}} or the {{Pkg|boinc-nox}} package. The latter omits [[Xorg]] dependencies, and is therefore suited for use on headless servers.<br />
<br />
Both packages install a [[Systemd#Using units|unit]] file named {{ic|boinc-client.service}}.<br />
<br />
You will also need to add yourself to the {{ic|boinc}} [[user group]] in order for the manager to connect.<br />
<br />
To generate the necessary files referenced in the next section, make sure to [[start]] {{ic|boinc-client.service}}.<br />
<br />
== Known issues ==<br />
<br />
=== Syslog spam ===<br />
<br />
On Wayland, and possibly also on X, you may notice a lot (one per second) of messages in the [[journal]] like:<br />
<br />
boinc[98508]: Authorization required, but no authorization protocol specified<br />
<br />
See [https://boinc.berkeley.edu/dev/forum_thread.php?id=14249] and [https://github.com/BOINC/boinc/issues/2256]. Until this is fixed, one workaround is to filter this message by creating the file {{ic|/etc/systemd/system/boinc-client.service.d/wayland-syslog-spam.conf}}, with the content<br />
<br />
[Service]<br />
LogFilterPatterns=~no authorization protocol specified<br />
<br />
which will filter that message from {{ic|boinc-client.service}} on systems with Systemd [https://github.com/systemd/systemd/blob/b9dac418372401742609bd600f05267ae3a724de/NEWS#L147-L152|>=253].<br />
<br />
== Using BOINC ==<br />
<br />
=== BOINC via the GUI ===<br />
<br />
By default, a password is created in {{ic|/var/lib/boinc/gui_rpc_auth.cfg}} for connecting to the daemon. To simplify connection of the GUI to the daemon, create a link to this file in your home directory.<br />
<br />
$ ln -s /var/lib/boinc/gui_rpc_auth.cfg ~/gui_rpc_auth.cfg<br />
<br />
Do not forget to add your user to the {{ic|boinc}} group as described above and then relogin or reboot.<br />
<br />
If you prefer a different password, or none at all, you can edit {{ic|/var/lib/boinc/gui_rpc_auth.cfg}}. Then restart BOINC daemon.<br />
<br />
If you do not like the idea of having this file in your home directory, there is an alternative approach. BOINC Manager will also look for a readable gui_rpc_auth.cfg file in the current working directory. If you make the file readable by the '''boinc''' group and ensure that the manager is run with {{ic|/var/lib/boinc}} as the working directory, you should find that the client connects to the daemon automatically, as desired. This can usually be achieved via the menu editor in your desktop environment of choice.<br />
<br />
To start the GUI, use the ''boincmgr'' command<br />
$ boincmgr<br />
<br />
BOINC should now take you through the process of attaching to a project. NB, some projects will let you create an account remotely via the GUI while some may require you to first create an account via their website. You can attach to multiple projects if you have the resources (disk space, time, CPU power). Do this via menu option ''Tools / Attach to project''.<br />
<br />
If BOINC did not ask you to connect to a project, then make sure you are connected to the daemon. Go to menu option ''Advanced / Select computer'', choose your machine's name and enter the password. (To avoid this, make sure the above steps regarding gui_rpc_auth.cfg have been done.)<br />
<br />
==== Projects using GPU ====<br />
<br />
If you want to use your GPU, you may need the proprietary nvidia or amd drivers.<br />
For newer AMD systems such as the Ryzen 5 2400G you can simply install {{AUR|opencl-amd}} on top of the open source [[AMDGPU]] to provide OpenCL capability for GPU work.<br />
For Nvidia, you also need the package {{Pkg|opencl-nvidia}} located in extra. To prevent computing errors, you most likely need the ''OpenGL (Multilib)'' package listed in [[Xorg#Driver installation]].<br />
<br />
In addition, the boinc user should be in the {{ic|video}} [[user group]].<br />
<br />
In order to suspend GPU computing when the computer is in use, the boinc user should have access to your X session so that mouse/keyboard input can be communicated to the client. This can be accomplished by installing the package {{Pkg|xorg-xhost}} (Extra) and executing the following command:<br />
<br />
$ xhost si:localuser:boinc<br />
<br />
You may want to [[Autostarting#On Xorg startup|autostart that on Xorg startup]].<br />
<br />
=== BOINC via the CLI ===<br />
<br />
Install {{pkg|boinc-nox}} to use BOINC on a headless system. Two command-line management tools are available: {{ic|boinccmd}} and {{ic|boinc}}. {{ic|boinccmd}} is recommended. To use {{ic|boinccmd}}, you must:<br />
<br />
# Start the BOINC service.<br />
# Provide {{ic|boinccmd}} with a password for communicating with the service's RPC API.<br />
<br />
To start the BOINC service, use the provided {{ic|boinc-client.service}} unit file. (For more information, see [[Systemd#Using units]].) The first time BOINC starts, it will generate a password and save it to {{ic|/var/lib/boinc/gui_rpc_auth.cfg}}. To provide {{ic|boinccmd}} with this password, consider one of the following:<br />
<br />
* Provide the password as a command-line flag, e.g. {{ic|boinccmd --passwd abc123 --get_host_info}}.<br />
* Ensure a file named {{ic|gui_rpc_auth.cfg}} is present in the current directory.<br />
<br />
That done, you can register with a project and attach BOINC to the project.<br />
<br />
To register with a project, you may be able to use the command-line client, or you may need to register with a separate website. To register with a project from the command-line, pick a project from [https://boinc.berkeley.edu/projects.php BOINC Project List], and execute a command like {{ic|boinccmd --passwd abc123 --create_account ${project_url} ${my_email} ${project_password} ${project_username} }}. Regardless of how you register, you must obtain a key for each project you would like BOINC to attach to. To attach BOINC to a project, execute a command like {{ic|boinccmd --passwd abc123 --project_attach ${project_url} ${project_key} }}.<br />
<br />
By default, BOINC uses at most 60% of available CPU time. If you wish to let boinc do more work, edit the CPU-related options in its configuration file:<br />
<br />
{{hc|/var/lib/boinc/global_prefs.xml|<global_preferences><br />
<cpu_usage_limit>100.0</cpu_usage_limit><br />
...<br />
</global_preferences>}}<br />
<br />
You can see other available [https://boinc.berkeley.edu/wiki/PreferencesXml XML configuration options] in the BOINC project's documentation.<br />
<br />
=== Controlling BOINC remotely ===<br />
<br />
A "remote" RPC is one that comes from a different computer.<br />
<br />
All remote RPCs (both status and control) are authenticated using the GUI RPC password.<br />
<br />
By default, remote RPCs are not accepted from any host. To specify a set of hosts from which RPCs are allowed, create a file {{ic|remote_hosts.cfg}} in your BOINC data directory containing a list of allowed DNS host names or IP addresses (one per line). Only these hosts will be able to connect. The {{ic|remote_hosts.cfg}} file can also have comment lines that start with either a # or a ; character.<br />
<br />
You can also set remote-allowed option in the options section of a {{ic|cc_config.xml}} file<br />
<br />
{{hc|/var/lib/boinc/cc_config.xml|<cc_config><br />
<options><br />
<allow_remote_gui_rpc>1</allow_remote_gui_rpc><br />
...<br />
</options><br />
</cc_config>}}<br />
<br />
You can see other available [https://boinc.berkeley.edu/wiki/Client_configuration Client configuration] in the BOINC project's documentation.<br />
<br />
Alternatively, if you run the client with the {{ic|--allow_remote_gui_rpc}} command line option, it will accept connections from any host (subject to password authentication). If you have a {{ic|remote_hosts.cfg}} file but also start the client with {{ic|--allow_remote_gui_rpc}}, the file will be ignored, and any host will be allowed to connect.<br />
<br />
Note that the "Read config file" on the BOINC Manager, Advanced menu will also read in the {{ic|remote_hosts.cfg}} file i.e. a restart of the client is not required to enable changes to the remote host list.<br />
<br />
== Log files ==<br />
<br />
BOINC places log files in {{ic|/var/lib/boinc/}}<br />
<br />
/var/lib/boinc/stderrdae.txt<br />
/var/lib/boinc/stdoutdae.txt<br />
<br />
== Considerations when choosing a project ==<br />
<br />
Projects have different minimum hardware requirements (CPU, disk space), and different times to taken to run each work unit. If you do not finish a work unit before the deadline it will sent out to someone else, but it is better to look around to see what projects suit your machine and your uptime patterns to avoid this happening. <br />
<br />
Also, if it is important to you, check if the project makes the data and results publicly available.<br />
<br />
=== Running 32bit projects ===<br />
<br />
Some projects provide only 32bit applications which may require 32bit libraries to run work units or show graphics. You will find most of these libraries in the [[multilib]] repository.<br />
<br />
To run WUs (e.g. Climateprediction), [[install]] {{Pkg|lib32-glibc}}, {{Pkg|lib32-glib2}}. <br />
<br />
To show graphics (e.g. Several projects of WCG, Climateprediction, Quake-Catcher Network), [[install]] {{Pkg|lib32-pango}}, {{Pkg|lib32-libxi}}, {{Pkg|lib32-mesa}}, {{Pkg|lib32-libjpeg6-turbo}}, {{Pkg|lib32-libxmu}}, {{Pkg|lib32-glu}} and {{Pkg|lib32-freeglut}}.<br />
<br />
== Troubleshooting ==<br />
<br />
=== GPU missing ===<br />
<br />
If you get this error :<br />
{{bc|GPU Missing}}<br />
and the Work Unit does not start, you should [[restart]] the {{ic|boinc-client.service}} daemon.<br />
<br />
This will happen if the BOINC daemon starts before the an X session is fully initialized.<br />
<br />
=== Laptop overheating and battery duration reduction ===<br />
<br />
{{Out of date|{{ic|ondemand}} is [https://github.com/archlinux/svntogit-packages/commit/2a8971f64f388d6e9e95ffb98f8c66d44eedf943 no longer] the default governor.}}<br />
<br />
If you run BOINC on a laptop with the {{ic|ondemand}} [[scaling governor]] (the default), it will keep the CPUs at their maximum frequencies, (over)heating them, and decreasing battery duration. The best way to fix this is to set {{ic|ondemand}} to not rise the CPU frequencies for BOINC:<br />
<br />
# echo 1 >/sys/devices/system/cpu/cpufreq/ondemand/ignore_nice_load<br />
<br />
To do this on boot, create the following [[tmpfile]] config:<br />
<br />
{{hc|/etc/tmpfiles.d/ondemand-ignore-nice.conf|<br />
w /sys/devices/system/cpu/cpufreq/ondemand/ignore_nice_load - - - - 1<br />
}}<br />
<br />
=== GPU work units insufficient memory ===<br />
<br />
When attempting OpenCL based work units you may get the error:<br />
<br />
Sorry, at the moment your system doesn't have enough free CPU/GPU memory to run this task!<br />
<br />
[[Edit]] the {{ic|boinc-client.service}} and modify the line:<br />
<br />
ProtectSystem=strict<br />
<br />
To:<br />
<br />
ProtectSystem=full<br />
<br />
To apply the changes, do a systemd [[daemon-reload]] and [[restart]] the {{ic|boinc-client.service}}.<br />
<br />
== See also ==<br />
<br />
* [https://boinc.berkeley.edu/ BOINC homepage]<br />
* [https://boinc.berkeley.edu/projects.php List of BOINC projects]<br />
* [[Wikipedia:BOINC|Wikipedia entry]]</div>Mackncheesiesthttps://wiki.archlinux.org/index.php?title=NVIDIA&diff=526681NVIDIA2018-06-17T20:46:59Z<p>Mackncheesiest: Clarified that DRM is an acronym for Direct Rendering Manager. It's a very minor concern, but some readers might interpret it as being related to Digital Rights Management and/or DRM video content playback</p>
<hr />
<div>[[Category:Graphics]]<br />
[[Category:X server]]<br />
[[cs:NVIDIA]]<br />
[[de:Nvidia]]<br />
[[es:NVIDIA]]<br />
[[fa:اِنویدیا]]<br />
[[fr:Nvidia]]<br />
[[it:NVIDIA]]<br />
[[ja:NVIDIA]]<br />
[[nl:NVIDIA]]<br />
[[ru:NVIDIA]]<br />
[[zh-hans:NVIDIA]]<br />
{{Related articles start}}<br />
{{Related|NVIDIA/Tips and tricks}}<br />
{{Related|NVIDIA/Troubleshooting}}<br />
{{Related|Nouveau}}<br />
{{Related|Bumblebee}}<br />
{{Related|NVIDIA Optimus}}<br />
{{Related|Xorg}}<br />
{{Related articles end}}<br />
<br />
This article covers the proprietary [http://www.nvidia.com NVIDIA] graphics card driver. For the open-source driver, see [[Nouveau]]. If you have a laptop with hybrid Intel/NVIDIA graphics, see [[NVIDIA Optimus]] instead.<br />
<br />
== Installation ==<br />
<br />
{{Warning|Avoid installing the NVIDIA driver through the package provided from the NVIDIA website. Installation through [[pacman]] allows upgrading the driver together with the rest of the system.}}<br />
<br />
These instructions are for those using the stock {{Pkg|linux}} or {{Pkg|linux-lts}} packages. For custom kernel setup, skip to the [[#Custom kernel|next]] subsection.<br />
<br />
1. If you do not know what graphics card you have, find out by issuing:<br />
:{{bc|<nowiki>$ lspci -k | grep -A 2 -E "(VGA|3D)"</nowiki>}}<br />
<br />
2. Determine the necessary driver version for your card by:<br />
:* finding the code name (e.g. NV50, NVC0, etc.) on [https://nouveau.freedesktop.org/wiki/CodeNames/ Nouveau wiki's code names page]<br />
:* looking up the name in NVIDIA's [http://www.nvidia.com/object/IO_32667.html legacy card list]: if your card is not there you can use the latest driver<br />
:* visiting NVIDIA's [http://www.nvidia.com/Download/index.aspx driver download site]<br />
<br />
3. Install the appropriate driver for your card:<br />
:* For GeForce 600 series cards and newer [NVEx and newer], [[install]] the {{Pkg|nvidia}} or {{Pkg|nvidia-lts}} package.<br />
::* If these packages do not work, {{AUR|nvidia-beta}} may have a newer driver version that offers support.<br />
::* There is also {{AUR|nvidia-llb-dkms}}, which is built from Nvidia's [http://www.phoronix.com/scan.php?page=news_item&px=OTkxOA long lived branch].<br />
:* For GeForce 400/500 series cards [NVCx and NVDx] from around 2010-2011, [[install]] the {{Pkg|nvidia-390xx}} or {{Pkg|nvidia-390xx-lts}} package.<br />
:* For GeForce 8/9, ION and 100-300 series cards [NV5x, NV8x, NV9x and NVAx] from around 2006-2010, [[install]] the {{Pkg|nvidia-340xx}} or {{Pkg|nvidia-340xx-lts}} package.<br />
<br />
:* For even older cards (released in 2006 or earlier), have a look at [[#Unsupported drivers]].<br />
<br />
4. For 32-bit application support, also install the equivalent ''lib32'' package from the [[multilib]] repository (e.g. {{Pkg|lib32-nvidia-utils}}, {{Pkg|lib32-nvidia-390xx-utils}} or {{Pkg|lib32-nvidia-340xx-utils}}).<br />
<br />
5. Reboot. The {{Pkg|nvidia}} package contains a file which blacklists the ''nouveau'' module, so rebooting is necessary.<br />
<br />
Once the driver has been installed, continue to [[#Configuration]].<br />
<br />
=== Unsupported drivers ===<br />
<br />
If you have a GeForce 7 series card or older (released in 2006 or earlier), Nvidia no longer supports drivers for your card. This means that these drivers [http://nvidia.custhelp.com/app/answers/detail/a_id/3142/ do not support the current Xorg version]. It thus might be easier if you use the [[Nouveau]] driver, which supports the old cards with the current Xorg.<br />
<br />
However, Nvidia's legacy drivers are still available and might provide better 3D performance/stability if you are willing to downgrade [[Xorg]]:<br />
<br />
* For GeForce 6/7 series cards [NV4x and NV6x], [[install]] the {{AUR|nvidia-304xx-dkms}}{{Broken package link|{{aur-mirror|nvidia-304xx-dkms}}}} package. Last supported Xorg version is 1.19.<br />
* For GeForce 5 FX series cards [NV30-NV36], install the {{AUR|nvidia-173xx-dkms}} package. Last supported Xorg version is 1.15.<br />
* For GeForce 2/3/4 MX/Ti series cards [NV11, NV17-NV28], install the {{AUR|nvidia-96xx-dkms}} package. Last supported Xorg version is 1.12.<br />
<br />
=== Custom kernel ===<br />
<br />
If you are using a custom kernel, compilation of the Nvidia kernel modules can be automated with [[DKMS]].<br />
<br />
Install the {{Pkg|nvidia-dkms}} package (or a specific branch such as {{Pkg|nvidia-390xx-dkms}} or {{Pkg|nvidia-340xx-dkms}}). The Nvidia module will be rebuilt after every Nvidia or kernel update thanks to the DKMS [[pacman hook]].<br />
<br />
=== DRM kernel mode setting ===<br />
<br />
{{Pkg|nvidia}} 364.16 adds support for DRM (Direct Rendering Manager) [[kernel mode setting]]. To enable this feature, add the {{ic|1=nvidia-drm.modeset=1}} [[kernel parameter]], and add {{ic|nvidia}}, {{ic|nvidia_modeset}}, {{ic|nvidia_uvm}} and {{ic|nvidia_drm}} to [[initramfs#MODULES]].<br />
<br />
Do not forget to run [[mkinitcpio]] every time there is a {{Pkg|nvidia}} driver update. See [[#Pacman hook]] to automate these steps.<br />
<br />
{{Warning|Enabling [[KMS]] causes [[GDM]] and [[GNOME]] to default to [[Wayland]], which currently suffers from very poor performance: {{bug|53284}}. A workaround is to configure GDM to use Xorg (see [[GDM#Use Xorg backend]]) or to use the ''GNOME on Xorg'' session instead.}}<br />
<br />
{{Note|1=The NVIDIA driver does '''not''' provide an {{ic|fbdev}} driver for the high-resolution console for the kernel compiled-in {{ic|vesafb}} module. However, the kernel compiled-in {{ic|efifb}} module supports a high-resolution console on EFI systems. This method requires GRUB and is described in [[NVIDIA/Tips and tricks#Fixing terminal resolution]].[http://forums.fedoraforum.org/showthread.php?t=306271][https://www.reddit.com/r/archlinux/comments/4gwukx/nvidia_drivers_and_high_resolution_tty_possible/].}}<br />
<br />
==== Pacman hook ====<br />
<br />
To avoid the possibility of forgetting to update [[initramfs]] after an NVIDIA driver upgrade, you may want to use a [[pacman hook]]:<br />
<br />
{{hc|/etc/pacman.d/hooks/nvidia.hook|2=[Trigger]<br />
Operation=Install<br />
Operation=Upgrade<br />
Operation=Remove<br />
Type=Package<br />
Target=nvidia<br />
<br />
[Action]<br />
Depends=mkinitcpio<br />
When=PostTransaction<br />
Exec=/usr/bin/mkinitcpio -P}}<br />
<br />
Make sure the {{ic|Target}} package set in this hook is the one you've installed in steps above (e.g. {{ic|nvidia}}, {{ic|nvidia-dkms}}, {{ic|nvidia-lts}} or {{ic|nvidia-ck-something}}).<br />
<br />
=== Hardware accelerated video decoding ===<br />
<br />
==== VDPAU ====<br />
<br />
At least a video card with second generation [[wikipedia:Nvidia PureVideo#Table of GPUs containing a PureVideo SIP block|PureVideo HD]] is required for [[hardware video acceleration]] using VDPAU.<br />
<br />
==== XvMC ====<br />
<br />
Accelerated decoding of MPEG-1 and MPEG-2 videos via [[XvMC]] are supported on GeForce4, GeForce 5 FX, GeForce 6 and GeForce 7 series cards. See [[XvMC]] for details.<br />
<br />
== Configuration ==<br />
<br />
The proprietary NVIDIA graphics card driver does not need any Xorg server configuration file. You can run [[Xorg#Running|a test]] to see if the Xorg server will function correctly without a configuration file. However, it may be required to create a configuration file (prefer {{ic|/etc/X11/xorg.conf.d/20-nvidia.conf}} over {{ic|/etc/X11/xorg.conf}}) in order to adjust various settings. This configuration can be generated by the NVIDIA Xorg configuration tool, or it can be created manually. If created manually, it can be a minimal configuration (in the sense that it will only pass the basic options to the [[Xorg]] server), or it can include a number of settings that can bypass Xorg's auto-discovered or pre-configured options.<br />
<br />
{{Tip|For more configuration options see [[NVIDIA/Tips and tricks#Manual configuration]] and [[NVIDIA/Troubleshooting]] section.}}<br />
<br />
=== Minimal configuration ===<br />
<br />
A basic configuration block in {{ic|20-nvidia.conf}} (or deprecated in {{ic|xorg.conf}}) would look like this:<br />
<br />
{{hc|/etc/X11/xorg.conf.d/20-nvidia.conf|<br />
Section "Device"<br />
Identifier "Nvidia Card"<br />
Driver "nvidia"<br />
VendorName "NVIDIA Corporation"<br />
BoardName "GeForce GTX 1050 Ti"<br />
EndSection<br />
}}<br />
<br />
=== Automatic configuration ===<br />
<br />
The NVIDIA package includes an automatic configuration tool to create an Xorg server configuration file ({{ic|xorg.conf}}) and can be run by:<br />
# nvidia-xconfig<br />
<br />
This command will auto-detect and create (or edit, if already present) the {{ic|/etc/X11/xorg.conf}} configuration according to present hardware.<br />
<br />
If there are instances of DRI, ensure they are commented out:<br />
# Load "dri"<br />
Double check your {{ic|/etc/X11/xorg.conf}} to make sure your default depth, horizontal sync, vertical refresh, and resolutions are acceptable.<br />
<br />
=== NVIDIA Settings ===<br />
<br />
The {{Pkg|nvidia-settings}} tool lets you configure many options using either CLI or GUI. Running {{ic|nvidia-settings}} without any options launches the GUI, for CLI options see {{man|1|nvidia-settings}}.<br />
<br />
You can run the CLI/GUI as a non-root user and save the settings to {{ic|~/.nvidia-settings-rc}} or save it as [[Xorg#Using_xorg.conf|xorg.conf]] by using the option ''Save to X configuration File'' for a multi-user environment.<br />
<br />
To load the {{ic|~/.nvidia-settings-rc}} for the current user:<br />
<br />
$ nvidia-settings --load-config-only<br />
<br />
See [[Autostarting]] to start this command on every boot.<br />
<br />
{{Note|[[Xorg]] may not start or crash on startup after saving {{ic|nvidia-settings}} changes. Adjusting or deleting the generated {{ic|~/.nvidia-settings-rc}} and/or [[Xorg]] file(s) should recover normal startup.}}<br />
<br />
=== Multiple monitors ===<br />
<br />
See [[Multihead]] for more general information.<br />
<br />
==== Using NVIDIA Settings ====<br />
<br />
The [[#NVIDIA Settings|nvidia-settings]] tool can configure multiple monitors.<br />
<br />
For CLI configuration, first get the {{ic|CurrentMetaMode}} by running:<br />
<br />
{{hc|$ nvidia-settings -q CurrentMetaMode|2=<br />
Attribute 'CurrentMetaMode' (hostnmae:0.0): id=50, switchable=no, source=nv-control :: DPY-1: 2880x1620 @2880x1620 +0+0 {ViewPortIn=2880x1620, ViewPortOut=2880x1620+0+0}<br />
}}<br />
<br />
Save everything after the {{ic|::}} to the end of the attribute (in this case: {{ic|1=DPY-1: 2880x1620 @2880x1620 +0+0 {ViewPortIn=2880x1620, ViewPortOut=2880x1620+0+0&#125;}}) and use to reconfigure your displays with {{ic|1=nvidia-settings --assign "CurrentMetaMode=''your_meta_mode''"}}.<br />
<br />
{{Tip|You can create shell aliases for the different monitor and resolution configurations you use.}}<br />
<br />
==== ConnectedMonitor ====<br />
<br />
If the driver does not properly detect a second monitor, you can force it to do so with ConnectedMonitor. <br />
<br />
{{hc|/etc/X11/xorg.conf|<br />
<br />
Section "Monitor"<br />
Identifier "Monitor1"<br />
VendorName "Panasonic"<br />
ModelName "Panasonic MICRON 2100Ex"<br />
HorizSync 30.0 - 121.0 # this monitor has incorrect EDID, hence Option "UseEDIDFreqs" "false"<br />
VertRefresh 50.0 - 160.0<br />
Option "DPMS"<br />
EndSection<br />
<br />
Section "Monitor"<br />
Identifier "Monitor2"<br />
VendorName "Gateway"<br />
ModelName "GatewayVX1120"<br />
HorizSync 30.0 - 121.0<br />
VertRefresh 50.0 - 160.0<br />
Option "DPMS"<br />
EndSection<br />
<br />
Section "Device"<br />
Identifier "Device1"<br />
Driver "nvidia"<br />
Option "NoLogo"<br />
Option "UseEDIDFreqs" "false"<br />
Option "ConnectedMonitor" "CRT,CRT"<br />
VendorName "NVIDIA Corporation"<br />
BoardName "GeForce 6200 LE"<br />
BusID "PCI:3:0:0"<br />
Screen 0<br />
EndSection<br />
<br />
Section "Device"<br />
Identifier "Device2"<br />
Driver "nvidia"<br />
Option "NoLogo"<br />
Option "UseEDIDFreqs" "false"<br />
Option "ConnectedMonitor" "CRT,CRT"<br />
VendorName "NVIDIA Corporation"<br />
BoardName "GeForce 6200 LE"<br />
BusID "PCI:3:0:0"<br />
Screen 1<br />
EndSection<br />
<br />
}}<br />
<br />
The duplicated device with {{ic|Screen}} is how you get X to use two monitors on one card without {{ic|TwinView}}. Note that {{ic|nvidia-settings}} will strip out any {{ic|ConnectedMonitor}} options you have added.<br />
<br />
==== TwinView ====<br />
<br />
You want only one big screen instead of two. Set the {{ic|TwinView}} argument to {{ic|1}}. This option should be used if you desire compositing. TwinView only works on a per card basis, when all participating monitors are connected to the same card.<br />
Option "TwinView" "1"<br />
<br />
Example configuration:<br />
{{hc|/etc/X11/xorg.conf.d/10-monitor.conf|<br />
Section "ServerLayout"<br />
Identifier "TwinLayout"<br />
Screen 0 "metaScreen" 0 0<br />
EndSection<br />
<br />
Section "Monitor"<br />
Identifier "Monitor0"<br />
Option "Enable" "true"<br />
EndSection<br />
<br />
Section "Monitor"<br />
Identifier "Monitor1"<br />
Option "Enable" "true"<br />
EndSection<br />
<br />
Section "Device"<br />
Identifier "Card0"<br />
Driver "nvidia"<br />
VendorName "NVIDIA Corporation"<br />
<br />
#refer to the link below for more information on each of the following options.<br />
Option "HorizSync" "DFP-0: 28-33; DFP-1 28-33"<br />
Option "VertRefresh" "DFP-0: 43-73; DFP-1 43-73"<br />
Option "MetaModes" "1920x1080, 1920x1080"<br />
Option "ConnectedMonitor" "DFP-0, DFP-1"<br />
Option "MetaModeOrientation" "DFP-1 LeftOf DFP-0"<br />
EndSection<br />
<br />
Section "Screen"<br />
Identifier "metaScreen"<br />
Device "Card0"<br />
Monitor "Monitor0"<br />
DefaultDepth 24<br />
Option "TwinView" "True"<br />
SubSection "Display"<br />
Modes "1920x1080"<br />
EndSubSection<br />
EndSection<br />
}}<br />
<br />
[ftp://download.nvidia.com/XFree86/Linux-x86/355.11/README/configtwinview.html Device option information].<br />
<br />
If you have multiple cards that are SLI capable, it is possible to run more than one monitor attached to separate cards (for example: two cards in SLI with one monitor attached to each). The "MetaModes" option in conjunction with SLI Mosaic mode enables this. Below is a configuration which works for the aforementioned example and runs [[GNOME]] flawlessly.<br />
{{hc|/etc/X11/xorg.conf.d/10-monitor.conf|<br />
Section "Device"<br />
Identifier "Card A"<br />
Driver "nvidia"<br />
BusID "PCI:1:00:0"<br />
EndSection<br />
<br />
Section "Device"<br />
Identifier "Card B"<br />
Driver "nvidia"<br />
BusID "PCI:2:00:0"<br />
EndSection<br />
<br />
Section "Monitor"<br />
Identifier "Right Monitor"<br />
EndSection<br />
<br />
Section "Monitor"<br />
Identifier "Left Monitor"<br />
EndSection<br />
<br />
Section "Screen"<br />
Identifier "Right Screen"<br />
Device "Card A"<br />
Monitor "Right Monitor"<br />
DefaultDepth 24<br />
Option "SLI" "Mosaic"<br />
Option "Stereo" "0"<br />
Option "BaseMosaic" "True"<br />
Option "MetaModes" "GPU-0.DFP-0: 1920x1200+4480+0, GPU-1.DFP-0:1920x1200+0+0"<br />
SubSection "Display"<br />
Depth 24<br />
EndSubSection<br />
EndSection<br />
<br />
Section "Screen"<br />
Identifier "Left Screen"<br />
Device "Card B"<br />
Monitor "Left Monitor"<br />
DefaultDepth 24<br />
Option "SLI" "Mosaic"<br />
Option "Stereo" "0"<br />
Option "BaseMosaic" "True"<br />
Option "MetaModes" "GPU-0.DFP-0: 1920x1200+4480+0, GPU-1.DFP-0:1920x1200+0+0"<br />
SubSection "Display"<br />
Depth 24<br />
EndSubSection<br />
EndSection<br />
<br />
Section "ServerLayout"<br />
Identifier "Default"<br />
Screen 0 "Right Screen" 0 0<br />
Option "Xinerama" "0"<br />
EndSection}}<br />
<br />
===== Manual CLI configuration with xrandr =====<br />
{{Accuracy|Do these commands set up the monitors in ''TwinView'' mode?}}<br />
<br />
If the latest solutions do not work for you, you can use your window manager's ''autostart'' implementation with {{Pkg|xorg-xrandr}}.<br />
<br />
Some {{ic|xrandr}} examples could be:<br />
<br />
xrandr --output DVI-I-0 --auto --primary --left-of DVI-I-1<br />
<br />
or:<br />
<br />
xrandr --output DVI-I-1 --pos 1440x0 --mode 1440x900 --rate 75.0<br />
<br />
When:<br />
<br />
* {{ic|--output}} is used to indicate the "monitor" to which the options are set.<br />
* {{ic|DVI-I-1}} is the name of the second monitor.<br />
* {{ic|--pos}} is the position of the second monitor relative to the first.<br />
* {{ic|--mode}} is the resolution of the second monitor.<br />
* {{ic|--rate}} is the refresh rate (in Hz).<br />
<br />
===== Vertical sync using TwinView =====<br />
<br />
If you are using TwinView and vertical sync (the "Sync to VBlank" option in '''nvidia-settings'''), you will notice that only one screen is being properly synced, unless you have two identical monitors. Although '''nvidia-settings''' does offer an option to change which screen is being synced (the "Sync to this display device" option), this does not always work. A solution is to add the following environment variables at startup, for example append in {{ic|/etc/profile}}:<br />
<br />
export __GL_SYNC_TO_VBLANK=1<br />
export __GL_SYNC_DISPLAY_DEVICE=DFP-0<br />
export VDPAU_NVIDIA_SYNC_DISPLAY_DEVICE=DFP-0<br />
<br />
You can change {{ic|DFP-0}} with your preferred screen ({{ic|DFP-0}} is the DVI port and {{ic|CRT-0}} is the VGA port). You can find the identifier for your display from '''nvidia-settings''' in the "X Server XVideoSettings" section.<br />
<br />
===== Gaming using TwinView =====<br />
<br />
In case you want to play fullscreen games when using TwinView, you will notice that games recognize the two screens as being one big screen. While this is technically correct (the virtual X screen really is the size of your screens combined), you probably do not want to play on both screens at the same time. <br />
<br />
To correct this behavior for SDL, try:<br />
export SDL_VIDEO_FULLSCREEN_HEAD=1<br />
<br />
For OpenGL, add the appropriate Metamodes to your xorg.conf in section {{ic|Device}} and restart X:<br />
Option "Metamodes" "1680x1050,1680x1050; 1280x1024,1280x1024; 1680x1050,NULL; 1280x1024,NULL;"<br />
<br />
Another method that may either work alone or in conjunction with those mentioned above is [[Gaming#Starting_games_in_a_separate_X_server|starting games in a separate X server]].<br />
<br />
==== Mosaic mode ====<br />
<br />
Mosaic mode is the only way to use more than 2 monitors across multiple graphics cards with compositing. Your window manager may or may not recognize the distinction between each monitor.<br />
<br />
===== Base Mosaic =====<br />
<br />
Base Mosaic mode works on any set of Geforce 8000 series or higher GPUs. It cannot be enabled from within the nvidia-setting GUI. You must either use the {{ic|nvidia-xconfig}} command line program or edit {{ic|xorg.conf}} by hand. Metamodes must be specified. The following is an example for four DFPs in a 2x2 configuration, each running at 1920x1024, with two DFPs connected to two cards:<br />
$ nvidia-xconfig --base-mosaic --metamodes="GPU-0.DFP-0: 1920x1024+0+0, GPU-0.DFP-1: 1920x1024+1920+0, GPU-1.DFP-0: 1920x1024+0+1024, GPU-1.DFP-1: 1920x1024+1920+1024"<br />
<br />
{{Note|While the documentation lists a 2x2 configuration of monitors, [https://devtalk.nvidia.com/default/topic/579449/linux/basemosaic-v295-vs-v310-vs-v325-only-up-to-three-screens-/post/3954733/#3954733 GeForce cards are artificially limited to 3 monitors] in Base Mosaic mode. Quadro cards support more than 3 monitors. As of September 2014, the Windows driver has dropped this artificial restriction, but it remains in the Linux driver.}}<br />
<br />
===== SLI Mosaic =====<br />
<br />
If you have an SLI configuration and each GPU is a Quadro FX 5800, Quadro Fermi or newer then you can use SLI Mosaic mode. It can be enabled from within the nvidia-settings GUI or from the command line with:<br />
$ nvidia-xconfig --sli=Mosaic --metamodes="GPU-0.DFP-0: 1920x1024+0+0, GPU-0.DFP-1: 1920x1024+1920+0, GPU-1.DFP-0: 1920x1024+0+1024, GPU-1.DFP-1: 1920x1024+1920+1024"<br />
<br />
=== Driver persistence ===<br />
<br />
Nvidia has a daemon that is to be run at boot. See the [http://docs.nvidia.com/deploy/driver-persistence/index.html#persistence-daemon Driver Persistence] section of the Nvidia documentation for more details.<br />
<br />
To start the persistence daemon at boot, [[enable]] the {{ic|nvidia-persistenced.service}}. For manual usage see the [http://docs.nvidia.com/deploy/driver-persistence/index.html#usage upstream documentation].<br />
<br />
== See also ==<br />
<br />
* [https://forums.geforce.com/ NVIDIA User forums]<br />
* [http://download.nvidia.com/XFree86/Linux-x86/387.22/README/README.txt Official README for NVIDIA drivers, all on one text page. Version 387.22 (2017-10-25)]<br />
* [http://download.nvidia.com/XFree86/Linux-x86/387.22/README/xconfigoptions.html README Appendix B. X Config Options, 387.22 (direct link)]</div>Mackncheesiest