tacticalrmm
tacticalrmm copied to clipboard
Permission Denied
Server Info (please complete the following information):
- OS: Centos :inux 7 (Core)
- RMM Version : 0.12.0
Installation Method:
-
[ ] Standard
-
Agent OS: Linux
Describe the bug When running the script it gives a Permissions Denied when creating the /tmp folder (Line 58)
To Reproduce Steps to reproduce the behavior:
- upload script
- CHmod file
- Run Script
- See error Line 58: /tmp/mesh-XXXXXX/meshagent: Permission Denied
Expected behavior Stop install of RMM
Screenshots If applicable, add screenshots to help explain your problem.
looks like same issue as https://github.com/amidaware/tacticalrmm/issues/1017
Please confirm, closing in 7 days if no additions
fixed in 0.12.1
Hi,
I am running V0.12.1 , created a linux install file again, went to run it and the same Permission Denied?
Any help would be greatly appreciated
Regard s
Any ideas or suggestions?
devs are very busy at the moment and really a question for them
This is probably better debugged in Discord, but would like to see: System info (os/where/version/who installed cpanel etc) Run debug install of agent, lots of private info in there, so make sure it's privately sent not posted publicly. Need to be able to replicate before we can debug/fix.
If this is a duplicate, let's close this ticket and troubleshoot this cpanel-related specific issue on the other ticket. If you think it's different please post other details
the other ticket was closed as well and seems to have been resolved, so i'll re-open this one as it's not a duplicate.
@rwcloudridgeworks can you please paste the contents of the install script you're using (just remove the sensitive info/urls at the top of the script) I just want to make sure you're using the script from 0.12.1 because that tmp directory that's being created doesn't look right, it should be falling back to the /root
dir not /tmp
#!/usr/bin/env bash
if [ $EUID -ne 0 ]; then echo "ERROR: Must be run as root" exit 1 fi
HAS_SYSTEMD=$(ps --no-headers -o comm 1) if [ "${HAS_SYSTEMD}" != 'systemd' ]; then echo "This install script only supports systemd" echo "Please install systemd or manually create the service using your systems's service manager" exit 1 fi
agentDL='https://agents.tacticalrmm.com/api/v1/linuxagents/?version=2.0.1&arch=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx meshDL='https://xxxxxxxxxxx.co.uk/meshagents?id=IVQGfjjmFS8Xhu1KHQGR1TF4QeC9ELIAyozmb47GcoO9bM7ra05tE5EJ$i$v6pbu&installflags=0&meshinstall=6'
apiURL='https://api.xxxxxxxxxx.co.uk' token='xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx' clientID='2' siteID='20' agentType='server' proxy=''
agentBinPath='/usr/local/bin' binName='tacticalagent' agentBin="${agentBinPath}/${binName}" agentConf='/etc/tacticalagent' agentSvcName='tacticalagent.service' agentSysD="/etc/systemd/system/${agentSvcName}" meshDir='/opt/tacticalmesh' meshSystemBin="${meshDir}/meshagent" meshSvcName='meshagent.service' meshSysD="/lib/systemd/system/${meshSvcName}"
deb=(ubuntu debian raspbian kali) rhe=(fedora rocky centos rhel amzn arch opensuse)
set_locale_deb() { locale-gen "en_US.UTF-8" localectl set-locale LANG=en_US.UTF-8 . /etc/default/locale }
set_locale_rhel() { localedef -c -i en_US -f UTF-8 en_US.UTF-8 > /dev/null 2>&1 localectl set-locale LANG=en_US.UTF-8 . /etc/locale.conf }
RemoveOldAgent() { if [ -f "${agentSysD}" ]; then systemctl disable --now ${agentSvcName} rm -f ${agentSysD} systemctl daemon-reload fi
if [ -f "${agentConf}" ]; then
rm -f ${agentConf}
fi
if [ -f "${agentBin}" ]; then
rm -f ${agentBin}
fi
}
InstallMesh() { if [ -f /etc/os-release ]; then distroID=$(. /etc/os-release; echo $ID) if [[ " ${deb[]} " =~ " ${distroID} " ]]; then set_locale_deb elif [[ " ${rhe[]} " =~ " ${distroID} " ]]; then set_locale_rhel else set_locale_rhel fi fi
meshTmpDir=$(mktemp -d -t "mesh-XXXXXXXXX")
if [ $? -ne 0 ]; then
meshTmpDir='meshtemp'
mkdir -p ${meshTmpDir}
fi
meshTmpBin="${meshTmpDir}/meshagent"
wget --no-check-certificate -q -O ${meshTmpBin} ${meshDL}
chmod +x ${meshTmpBin}
mkdir -p ${meshDir}
env LC_ALL=en_US.UTF-8 LANGUAGE=en_US ${meshTmpBin} -install --installPath=${meshDir}
sleep 1
rm -rf ${meshTmpDir}
}
RemoveMesh() { if [ -f "${meshSystemBin}" ]; then ${meshSystemBin} -uninstall sleep 1 fi
if [ -f "${meshSysD}" ]; then
systemctl disable --now ${meshSvcName} > /dev/null 2>&1
rm -f ${meshSysD}
fi
rm -rf ${meshDir}
systemctl daemon-reload
}
Uninstall() { RemoveMesh RemoveOldAgent }
if [ $# -ne 0 ] && [ $1 == 'uninstall' ]; then Uninstall exit 0 fi
RemoveOldAgent
echo "Downloading tactical agent..." wget -q -O ${agentBin} "${agentDL}" chmod +x ${agentBin}
MESH_NODE_ID=""
if [ $# -ne 0 ] && [ $1 == '--nomesh' ]; then echo "Skipping mesh install" else if [ -f "${meshSystemBin}" ]; then RemoveMesh fi echo "Downloading and installing mesh agent..." InstallMesh sleep 2 echo "Getting mesh node id..." MESH_NODE_ID=$(${agentBin} -m nixmeshnodeid) fi
if [ ! -d "${agentBinPath}" ]; then echo "Creating ${agentBinPath}" mkdir -p ${agentBinPath} fi
if [ $# -ne 0 ] && [ $1 == '--debug' ]; then INSTALL_CMD="${agentBin} -m install -api ${apiURL} -client-id ${clientID} -site-id ${siteID} -agent-type ${agentType} -auth ${token} -log debug" else INSTALL_CMD="${agentBin} -m install -api ${apiURL} -client-id ${clientID} -site-id ${siteID} -agent-type ${agentType} -auth ${token}" fi
if [ "${MESH_NODE_ID}" != '' ]; then INSTALL_CMD+=" -meshnodeid ${MESH_NODE_ID}" fi
if [ "${proxy}" != '' ]; then INSTALL_CMD+=" -proxy ${proxy}" fi
eval ${INSTALL_CMD}
tacticalsvc="$(cat << EOF [Unit] Description=Tactical RMM Linux Agent
[Service] Type=simple ExecStart=${agentBin} -m svc User=root Group=root Restart=always RestartSec=5s LimitNOFILE=1000000 KillMode=process
[Install] WantedBy=multi-user.target EOF )" echo "${tacticalsvc}" | tee ${agentSysD} > /dev/null
systemctl daemon-reload systemctl enable --now ${agentSvcName}
Is this still an issue, or could this be closed?
Good morning, all
I the server restarted last night and will not load do a force update and got the below errors
npm ERR! code ENOLOCK npm ERR! audit This command requires an existing lockfile. npm ERR! audit Try creating one first with: npm i --package-lock-only npm ERR! audit Original error: loadVirtual requires existing shrinkwrap file
npm ERR! A complete log of this run can be found in: npm ERR! /root/.npm/_logs/2022-08-23T11_09_27_491Z-debug-0.log
steve
Kind regards Stephen Oxley Managing Director 01132166777Tel: 07793444814 @.*** 2 Kerry Hill, Horsforth, Leeds. LS18 4AY www.ridgeworks.co.uk Please note - Support requests must be emailed to: @.** P Please consider the environment before printing this e-mail. Ridgeworks DS Ltd accepts no liability for the content of this email, or for the consequences of any actions taken on the basis of the information provided, unless that information is subsequently confirmed in writing. Any views or opinions presented in this email are solely those of the author and do not necessarily represent those of the company.Please click to view our terms and conditions or here for our Privacy Policy. Ridgeworks DS LTD is a company registered in England and Wales under number -11011886 Vat :- GB336645094. Registered office: 2 Kerry Hill Horsforth Leeds LS18 4AY From: dinger1986 @.> Sent: 30 March 2022 09:57 To: amidaware/tacticalrmm @.> Cc: Stephen Oxley @.>; Author @.> Subject: Re: [amidaware/tacticalrmm] Permission Denied (Issue #1015)
devs are very busy at the moment and really a question for them
— Reply to this email directly, view it on GitHubhttps://github.com/amidaware/tacticalrmm/issues/1015#issuecomment-1082808175, or unsubscribehttps://github.com/notifications/unsubscribe-auth/APASS6MGQMQOCUUL7R2JRDLVCQJM5ANCNFSM5RK56IHQ. You are receiving this because you authored the thread.Message ID: @.@.>>
This sounds like a different issue.
What do you think the issue is ?
Steve
Kind regards Stephen Oxley Managing Director 01132166777Tel: 07793444814 @.*** 2 Kerry Hill, Horsforth, Leeds. LS18 4AY www.ridgeworks.co.uk Please note - Support requests must be emailed to: @.** P Please consider the environment before printing this e-mail. Ridgeworks DS Ltd accepts no liability for the content of this email, or for the consequences of any actions taken on the basis of the information provided, unless that information is subsequently confirmed in writing. Any views or opinions presented in this email are solely those of the author and do not necessarily represent those of the company.Please click to view our terms and conditions or here for our Privacy Policy. Ridgeworks DS LTD is a company registered in England and Wales under number -11011886 Vat :- GB336645094. Registered office: 2 Kerry Hill Horsforth Leeds LS18 4AY From: dinger1986 @.> Sent: 23 August 2022 12:22 To: amidaware/tacticalrmm @.> Cc: Stephen Oxley @.>; Mention @.> Subject: Re: [amidaware/tacticalrmm] Permission Denied (Issue #1015)
This sounds like a different issue.
— Reply to this email directly, view it on GitHubhttps://github.com/amidaware/tacticalrmm/issues/1015#issuecomment-1223927984, or unsubscribehttps://github.com/notifications/unsubscribe-auth/APASS6PSRPCGBS3A4FE2ZOLV2SX67ANCNFSM5RK56IHQ. You are receiving this because you were mentioned.Message ID: @.@.>>
This started as a ticket about trying to install linux agent, now it's about trying to update TRMM server?