You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@trafficserver.apache.org by "Zhao Yongming (Commented) (JIRA)" <ji...@apache.org> on 2012/04/05 06:14:48 UTC
[jira] [Commented] (TS-1085) traffic_shell enable command doesn't
work
[ https://issues.apache.org/jira/browse/TS-1085?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13246999#comment-13246999 ]
Zhao Yongming commented on TS-1085:
-----------------------------------
I think that is because of traffic_shell & traffic_line need write permission on the unix socks, where in most case they are owned by nobody or ats, and permission 0755:
{code}
[root@test55 trafficserver]# ls -l /var/run/trafficserver/ | grep ^s
srwxr-xr-x 1 ats ats 0 Apr 5 10:09 eventapisocket
srwxr-xr-x 1 ats ats 0 Apr 5 10:09 mgmtapisocket
srwxr-xr-x 1 ats ats 0 Apr 5 10:09 process_server
{code}
in any way, you can not write to those socks unless you are root, that is why traffic_line & traffic_shell need the root privileges.
> traffic_shell enable command doesn't work
> -----------------------------------------
>
> Key: TS-1085
> URL: https://issues.apache.org/jira/browse/TS-1085
> Project: Traffic Server
> Issue Type: Bug
> Components: Management
> Reporter: James Peach
> Assignee: James Peach
> Fix For: 3.3.0
>
>
> Let's try this as root:
> blacko:trafficserver.git jpeach$ sudo /opt/ats/bin/traffic_shell
> Successfully Initialized MgmtAPI in /opt/ats/var/trafficserver
> % trafficserver> enable
> Already Enabled
> trafficserver> exit
> Ok, to let's try as non-root:
> blacko:trafficserver.git jpeach$ /opt/ats/bin/traffic_shell
> [connect] ERROR (main_socket_fd 3): Permission denied
> TSInit 5: Failed to initialize MgmtAPI in /opt/ats/var/trafficserver
> [connect] ERROR (main_socket_fd 3): Permission denied
> % trafficserver> enable
> FATAL: ConfigCmd.cc:137: failed assert `enable_restricted_commands`
> /opt/ats/bin/traffic_shell - STACK TRACE:
> 0 libtsutil.3.dylib 0x000000010cec8b8b ink_fatal_va + 283
> 1 libtsutil.3.dylib 0x000000010cec8e94 ink_fatal + 356
> 2 libtsutil.3.dylib 0x000000010cec66ff _ink_assert + 271
> 3 traffic_shell 0x000000010ce253ab _Z10Cmd_EnablePvP10Tcl_InterpiPPKc + 395
> 4 Tcl 0x000000010cf34261 TclInvokeStringCommand + 121
> 5 Tcl 0x000000010cf360b7 Tcl_GetMathFuncInfo + 2533
> 6 Tcl 0x000000010cf36d14 Tcl_GetMathFuncInfo + 5698
> 7 Tcl 0x000000010cf370d2 Tcl_Eval + 42
> So either enable does nothing or it crashes. Seems like we should fix or remove this.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira