-
Notifications
You must be signed in to change notification settings - Fork 226
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(fedora): add nvidia proprietary driver setup script #319
Conversation
This script allows us to install/remove nvidia driver in fedora system safely.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We've refactored the scripts to remove most of the Bash-specific notations and ensure they are POSIX-compliant (sh). Please review the changes. You can also checkout my https://github.com/jeevithakannan2/linutil/tree/fedora-nvidia for your reference for this PR
src/commands/system-setup/fedora/nvidia-proprietary-driver-setup.sh
Outdated
Show resolved
Hide resolved
src/commands/system-setup/fedora/nvidia-proprietary-driver-setup.sh
Outdated
Show resolved
Hide resolved
src/commands/system-setup/fedora/nvidia-proprietary-driver-setup.sh
Outdated
Show resolved
Hide resolved
src/commands/system-setup/fedora/nvidia-proprietary-driver-setup.sh
Outdated
Show resolved
Hide resolved
src/commands/system-setup/fedora/nvidia-proprietary-driver-setup.sh
Outdated
Show resolved
Hide resolved
src/commands/system-setup/fedora/nvidia-proprietary-driver-setup.sh
Outdated
Show resolved
Hide resolved
src/commands/system-setup/fedora/nvidia-proprietary-driver-setup.sh
Outdated
Show resolved
Hide resolved
src/commands/system-setup/fedora/nvidia-proprietary-driver-setup.sh
Outdated
Show resolved
Hide resolved
src/commands/system-setup/fedora/nvidia-proprietary-driver-setup.sh
Outdated
Show resolved
Hide resolved
src/commands/system-setup/fedora/nvidia-proprietary-driver-setup.sh
Outdated
Show resolved
Hide resolved
with the help of @jeevithakannan2 and his script as reference, I modified my script to be posix compliant. I've also tested this script with some modification and it works perfectly.
@jeevithakannan2 I made changes according to your suggestion, and also I've used your script as reference to modify my own script. I modified some changes from your script and tested on my own system, the script works way better than the previous iteration. |
src/commands/system-setup/fedora/nvidia-proprietary-driver-setup.sh
Outdated
Show resolved
Hide resolved
…Tool` at starting of the script as suggested by @nnyyxxxx, I made some changes according to his review
Should I Add VAAPI drivers, as an option for video acceleration? @nnyyxxxx, @jeevithakannan2 |
Yeah you could do that, also check whether the user's graphics card is compatible before proceeding with vaapi drivers installation |
@jeevithakannan2, Do you have any idea how I can check that? |
It would be something like this if command_exists nvidia-smi; then
gpu_info=$(nvidia-smi --query-gpu=name --format=csv,noheader)
printf "%b\n" "${GREEN}NVIDIA GPU detected: $gpu_info${RC}"
else
printf "%b\n" "${RED}nvidia-smi not found or drivers not installed.{RC}"
exit 1
fi
if echo "$gpu_info" | grep -Eq "GeForce (8|9|[1-9][0-9])|GTX|RTX"; then
printf "%b\n" "${GREEN}Your GPU ($gpu_model) is GeForce 8 series or above.${RC}"
else
printf "%b\n" "${RED}Your GPU ($gpu_model) is below GeForce 8 series.${RC}"
fi Add few more informational message for users and it is a sample script develop your own script based on that |
Yeah! This'll help a lot thanks @jeevithakannan2 |
Sorry for the inconvenience. We had a massive restructure of the codebase to improve future development. Because of this can you update your PR to the new structure. Thank you for your assistance and contribution. |
Okay @ChrisTitusTech, I'll do it now, and also thanks for checking in. |
Temporary removing nvidia toml entry for rebasing with latest commit
This reverts commit 1d732df.
} | ||
|
||
echo "1. Install Nvidia Drivers" | ||
echo "2. Remove Nvidia Drivers" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No need for the uninstalling feature, see #362 for more information.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To resolve conflicts, Should I delete this pull request and create a fresh one?
So, I don't know how I can fix this issue so I'm going to create a new pull request, with proper precaution. |
…from PR #319) (#370) * feat(fedora/nvidia-*.sh): adding nvidia proprietary driver setup * fix(fedora/nvidia-*.sh): removing update line That update line crashed my system while testing, since it also installed new kernal where I didn't build my driver. So new user can also get confused. * refactor(fedora/nvidia-*.sh): adding a new warning while starting the script I faced this issue yesterday, So It's better to warn user before installing this driver * refactor(fedora/nvidia-*.sh): removing uninstalation option For now, as suggested by @nnyyxxxx and @adamperkowski, I'm removing the uninstall option until #362 gets resolved. * Fix bashism --------- Co-authored-by: Chris Titus <contact@christitus.com>
Pull Request
Type of Change
Description
This script allows fedora user to install and remove proprietary NVIDIA drivers properly, without locking their system to infinity state on startup.
Testing
Additional Information
Checklist