[FUG-BR] Cannot open '/var/log/squid/access.log' for writing

Joao Rocha Braga Filho goffredo em gmail.com
Terça Junho 17 02:57:58 BRT 2008


2008/6/17 Paulo Henrique <paulo.rddck at bsd.com.br>:
> ls -l /var/log/squid/
>
> Assim teremos as prmissões dos arquivos de logs !!! :D

Ele instalou dos ports e usou um how-to para configurar que
não foi feito para FreeBSD. Os diretórios do how-to estão
errados. As permissões estão corretas, pelo que se vê da
resposta dada às minhas primeiras perguntas.


João Rocha.


>
>
> 2008/6/17 Julio Cardoso <julio.linuxgroups at gmail.com>:
>
>> Pode ser permissão de gravar apenas
>> Joao Rocha Braga Filho escreveu:
>> > 2008/6/17 Julio Cardoso <julio.linuxgroups at gmail.com>:
>> >
>> >> chmod 777 -R  /var/log/squid/MArvelrat escreveu:
>> >>
>> >
>> > Nem pense em fazer isto. Dar permissão total para algo que não
>> > está funcionando não é a solução, e cria um risco desnecessário.
>> > Mas neste caso daria "No such file or directory".
>> >
>> >
>> > João Rocha.
>> >
>> >
>> >>> Ae pessoal
>> >>>
>> >>> to tendo um probleminha ao configurar o squid
>> >>> começo..faço o basicao ae blz....
>> >>> agora qdo terminei de configurar uma acl pra bloquear uns sites
>> >>> perversos hehehe
>> >>> fui dar
>> >>> squid -k reconfigure
>> >>>
>> >>> ae a seguinte msg:
>> >>> squid: ERROR: Could not send signal 1 to process 7063: (3) No such
>> process
>> >>>
>> >>> a partir desse erro dei alguns comandos para ver oq se passava:
>> >>>
>> >>> squid -d5
>> >>>
>> >>> /2008/06/16 23:23:00| Starting Squid Cache version 2.6.STABLE20 for
>> >>> i386-portbld-freebsd7.0...
>> >>> 2008/06/16 23:23:00| Process ID 1180
>> >>> 2008/06/16 23:23:00| With 7040 file descriptors available
>> >>> 2008/06/16 23:23:00| Using kqueue for the IO loop
>> >>> 2008/06/16 23:23:00| Performing DNS Tests...
>> >>> 2008/06/16 23:23:00| Successful DNS name lookup tests...
>> >>> 2008/06/16 23:23:00| DNS Socket created at 0.0.0.0, port 56544, FD 6
>> >>> 2008/06/16 23:23:00| Adding domain cefidteste from /etc/resolv.conf
>> >>> 2008/06/16 23:23:00| Adding nameserver 200.X.X.X from /etc/resolv.conf
>> >>> FATAL: Cannot open '/var/log/squid/access.log' for writing.
>> >>>         The parent directory must be writeable by the
>> >>>         user 'squid', which is the cache_effective_user
>> >>>         set in squid.conf./
>> >>>
>> >>> squid -N -d 1 -D e squid -DNYCd3
>> >>>
>> >>>  dá a mesma coisa
>> >>>
>> >>> Squid.conf
>> >>>
>> >>> /http_port 3128
>> >>> visible_hostname meuservidorr/
>> >>>
>> >>> /cache_mem 64 MB
>> >>> maximum_object_size_in_memory 64 KB
>> >>> maximum_object_size 350 MB
>> >>> minimum_object_size 0 KB
>> >>> cache_swap_low 90
>> >>> cache_swap_high 95
>> >>> cache_dir ufs /var/spool/squid 512 16 256
>> >>> cache_access_log /var/log/squid/access.log
>> >>> refresh_pattern ^ftp: 15 20% 2280
>> >>> refresh_pattern ^gopher: 15 0% 2280
>> >>> refresh_pattern . 15 20% 2280/
>> >>>
>> >>> /acl all src 0.0.0.0/0.0.0.0
>> >>> acl manager proto cache_object
>> >>> acl localhost src 127.0.0.1/255.255.255.255
>> >>> acl SSL_ports port 443 563
>> >>> acl Safe_ports port 80 # http
>> >>> acl Safe_ports port 21 # ftp
>> >>> acl Safe_ports port 443 563 # https, snews
>> >>> acl Safe_ports port 70 # gopher
>> >>> acl Safe_ports port 210 # wais
>> >>> acl Safe_ports port 1025-65535 # unregistered ports
>> >>> acl Safe_ports port 280 # http-mgmt
>> >>> acl Safe_ports port 488 # gss-http
>> >>> acl Safe_ports port 591 # filemaker
>> >>> acl Safe_ports port 777 # multiling http
>> >>> acl Safe_ports port 901 # SWAT
>> >>> acl purge method PURGE
>> >>> acl CONNECT method CONNECT/
>> >>>
>> >>> /http_access allow manager localhost
>> >>> http_access deny manager
>> >>> http_access allow purge localhost
>> >>> http_access deny purge
>> >>> http_access deny !Safe_ports
>> >>> http_access deny CONNECT !SSL_ports/
>> >>>
>> >>> /*acl bloqueados url_regex -i "/etc/squid/bloqueados"
>> >>> http_access deny bloqueados*/
>> >>>
>> >>> /acl redelocal src 192.168.1.0/24*
>> >>> *http_access allow localhost
>> >>> http_access allow redelocal/
>> >>>
>> >>> /http_access deny all/
>> >>>
>> >>>
>> >>> config bem simples....
>> >>> Ah...usei chown para o arquivo que acusa que nao pode ser aberto para
>> >>> escrita....permissao e afins
>> >>>
>> >>> o estranho eh q do nada ele dá isso...
>> >>> qdo comecei..testei o squid so com o a config basica....dando a
>> >>> porta..liberando tudo etc etc
>> >>>
>> >>> setei la o endereço no browser foi blz....
>> >>> mas agora....
>> >>>
>> >>> abraço
>> >>>
>> >>>
>> >>>
>> >>>
>> >>>
>> >>>
>> >>>
>> >>>
>> >>> -------------------------
>> >>> Histórico: http://www.fug.com.br/historico/html/freebsd/
>> >>> Sair da lista: https://www.fug.com.br/mailman/listinfo/freebsd
>> >>>
>> >>>
>> >>>
>> >> -------------------------
>> >> Histórico: http://www.fug.com.br/historico/html/freebsd/
>> >> Sair da lista: https://www.fug.com.br/mailman/listinfo/freebsd
>> >>
>> >>
>> >
>> >
>> >
>> >
>>
>> -------------------------
>> Histórico: http://www.fug.com.br/historico/html/freebsd/
>> Sair da lista: https://www.fug.com.br/mailman/listinfo/freebsd
>>
>
>
>
> --
> Atenciosamente Paulo Henrique.
> -------------------------
> Histórico: http://www.fug.com.br/historico/html/freebsd/
> Sair da lista: https://www.fug.com.br/mailman/listinfo/freebsd
>



-- 
"Sempre se apanha mais com as menores besteiras. Experiência própria."

goffredo at goffredo.eti.br
goffredo at gmail.com
http://www.goffredo.eti.br


Mais detalhes sobre a lista de discussão freebsd