GNU/Linux >> Tutoriels Linux >  >> Cent OS

Comment exécuter Google Chrome en tant que root sur CentOS 7 / RHEL 7

Dans mon dernier post, je vous ai montré comment installer Google Chrome sur CentOS 7 / RHEL 7; lorsque j'ai essayé de démarrer Google Chrome, cela m'a donné l'erreur suivante.

 Après une longue recherche sur Google, j'ai trouvé un moyen simple pour permettre à l'utilisateur root d'exécuter Google Chrome.

Suivez les étapes pour exécuter Google Chrome en tant qu'utilisateur root dans CentOS 7 /RHEL 7 .

Ouvrez Terminal (Applications -> Outils système -> Terminal ).

Modifiez le /usr/bin/google-chrome et ajoutez le "–user-data-dir" à la fin de la dernière ligne (Ligne No :84 ).

[root@geeksite~/]# vi /usr/bin/google-chrome

Avant

exec < /dev/null 
exec > >(exec cat)
exec 2> >(exec cat >&2)

# Note: exec -a below is a bashism.
exec -a "$0" "$HERE/chrome"  "$PROFILE_DIRECTORY_FLAG" \
  "$@"

Après

exec < /dev/null 
exec > >(exec cat)
exec 2> >(exec cat >&2)

# Note: exec -a below is a bashism.
exec -a "$0" "$HERE/chrome"  "$PROFILE_DIRECTORY_FLAG" \
  "$@" --user-data-dir

C'est tout. Vous pouvez maintenant démarrer Google Chrome à partir du menu en tant que root.


Cent OS
  1. Comment installer Google Chrome 17 sur Fedora 16, CentOS 6 / RHEL 6

  2. Comment installer TeamViewer sur CentOS 6 / RHEL 6

  3. Comment exécuter Google Chrome en tant que root – Ubuntu 11.10 / Linux Mint 12

  4. Comment exécuter Google Chrome en tant que root sur openSUSE 12.1

  5. Comment exécuter rsyslog en tant qu'utilisateur non root dans CentOS/RHEL 7

Comment installer MariaDB sur CentOS 6 / RHEL 6

Comment installer Google Chrome sur CentOS 8 / RHEL 8

Comment installer Google Chrome sur CentOS

Comment installer Google Chrome sur CentOS 7

Comment installer Google Chrome sur CentOS 8

CentOS / RHEL 7 :Comment réinitialiser le mot de passe root