ajuda para permissões do usuário e acesso ao diretório de arquivos mac OS Sierra

0

Estou tentando classificar meus usrers e a permissão do usser no terminal para instalar as gemas do Ruby e outras bibliotecas, mas não chegar a lugar algum por causa das permissões negadas. Etapas que tentei:

  1. Tive uma chamada com apple para resolver minhas permissões de usuário, executei este comando

    diskutil resetUserPermissions / id -u

OBSERVAÇÃO: id -u estava em '' (a edição de código é descartada aqui). Não funcionou. ainda recebendo erros de permissão.

  1. Tentou executar o Postgres (instalado a partir da GUI), obtendo

    FATAL FATAL: role "Berzins" does not exist); (FATAL: data directory "/Users/Linards/Library/Application Support/Postgres/var-9.6" has group or world access DETAIL: Permissions should be u=rwx (0700)

No terminal eu sou:

Linards:~ Berzins$ whoami
Berzins
Linards:~ Berzins$
  1. Ran o seguinte no terminal:

Linards:~ Berzins$ dscl . -read /Groups/admin /System/Library/LaunchDaemons/com.apple.DirectoryServicesLocal.plist: No such file or directory AppleMetaNodeLocation: /Local/Default GeneratedUID: ABCDEFAB-CDEF-ABCD-EFAB-CDEF00000050 GroupMembers: FFFFEEEE-DDDD-CCCC-BBBB-AAAA00000000 6F8DC3A8-D4B6-4175-B24A-1A99756706FA GroupMembership: root Linards Berzins Linards Linards Berzins Password: * PrimaryGroupID: 80 RealName: Administrators RecordName: admin BUILTIN\Administrators RecordType: dsRecTypeStandard:Groups SMBSID: S-1-5-32-544 Linards:~ Berzins$ dscl . -read /Groups/staff /System/Library/LaunchDaemons/com.apple.DirectoryServicesLocal.plist: No such file or directory AppleMetaNodeLocation: /Local/Default GeneratedUID: ABCDEFAB-CDEF-ABCD-EFAB-CDEF00000014 GroupMembers: FFFFEEEE-DDDD-CCCC-BBBB-AAAA00000000 6F8DC3A8-D4B6-4175-B24A-1A99756706FA FFFFEEEE-DDDD-CCCC-BBBB-AAAA000000ED FFFFEEEE-DDDD-CCCC-BBBB-AAAA000000EE GroupMembership: root Berzins _xcsbuildagent _xcscredserver Password: * PrimaryGroupID: 20 RealName: Staff RecordName: staff BUILTIN\Users RecordType: dsRecTypeStandard:Groups SMBSID: S-1-5-32-545 Linards:~ Berzins$

E isso:

Linards:~ Berzins$ id uid=501(Berzins) gid=20(staff) groups=20(staff),701(com.apple.sharepoint.group.1),12(everyone),61(localaccounts),79(_appserverusr),80(admin),81(_appserveradm),98(_lpadmin),33(_appstore),100(_lpoperator),204(_developer),395(com.apple.access_ftp),398(com.apple.access_screensharing),399(com.apple.access_ssh) Linards:~ Berzins$

  1. Em seguida, correu o seguinte:

Linards:~ Berzins$ dscl . append /Groups/admin GroupMembership Linards /System/Library/LaunchDaemons/com.apple.DirectoryServicesLocal.plist: No such file or directory <main> attribute status: eDSPermissionError <dscl_cmd> DS Error: -14120 (eDSPermissionError) Linards:~ Berzins$ dscl . append /Groups/admin GroupMembership Berzins /System/Library/LaunchDaemons/com.apple.DirectoryServicesLocal.plist: No such file or directory <main> attribute status: eDSPermissionError <dscl_cmd> DS Error: -14120 (eDSPermissionError) Linards:~ Berzins$

Agora estou imerso em massa.

Qualquer ajuda apreciada.

    
por Linards Berzins 18.05.2017 / 08:35

1 resposta

0

De uma discussão offline, eu entendi que você estava tentando instalar o postgresql no macOS.

Na documentação :

Homebrew

PostgreSQL can also be installed on macOS using Homebrew. Please see the Homewbrew documentation for information on how to install packages.

  1. Instale o homebrew : %código%
  2. Instale o postgresql do terminal: /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" .

Minha saída:

$ brew install postgresql
Updating Homebrew...
==> Auto-updated Homebrew!


==> Downloading https://homebrew.bintray.com/bottles/postgresql-9.6.3.sierra.bot
######################################################################## 100.0%
==> Pouring postgresql-9.6.3.sierra.bottle.tar.gz
==> Using the sandbox
==> /usr/local/Cellar/postgresql/9.6.3/bin/initdb /usr/local/var/postgres
==> Caveats
If builds of PostgreSQL 9 are failing and you have version 8.x installed,
you may need to remove the previous version first. See:
  https://github.com/Homebrew/legacy-homebrew/issues/2510

To migrate existing data from a previous major version (pre-9.0) of PostgreSQL, see:
  https://www.postgresql.org/docs/9.6/static/upgrading.html

To migrate existing data from a previous minor version (9.0-9.5) of PostgreSQL, see:
  https://www.postgresql.org/docs/9.6/static/pgupgrade.html

  You will need your previous PostgreSQL installation from brew to perform 'pg_upgrade'.
  Do not run 'brew cleanup postgresql' until you have performed the migration.

To have launchd start postgresql now and restart at login:
  brew services start postgresql
Or, if you don't want/need a background service you can just run:
  pg_ctl -D /usr/local/var/postgres start
==> Summary
                                    
por 20.05.2017 / 10:23