Home General Discussion

Cireson.Platform.Host is eating up space

Bryant_RichardsBryant_Richards Customer IT Monkey ✭
Cireson.Platform.Host is eating up lots of space on our hard drive. Its 32Gb of log files going back to April. What can we remove safely to free up space on the drive? How critical are those files? Any suggestions on better areas to free up space on our Cireson server?

Thanks for the help!

Best Answers

  • Brian_WiestBrian_Wiest Customer Super IT Monkey ✭✭✭✭✭
    Answer ✓
    If at all interested here is a script for keeping the environment "clean".
    Couple notes.
    All Workflow logging from SCSM/Cireson (ie Notify Analyst logging and Asset Import) I have going to the local server E:\Logging\[Workflow Name]
    Also I have a weekly script that runs in the middle of the night that stops all SCSM services and the portal. I have it rename the webconsole.log and cachebuilder.log so the size doesn't balloon on me. (Which it has in the past)
    Make note of the -Recurse on some paths vs others. Some of the Cireson paths have files in nested folders that need to remain.
    This is setup via daily task manager. Helps make use I don't run out of file space just for logging files.
    HTH

    $scsmServers = @("server-scms131","server-scms132","server-scms133","server-scms134","server-scms135","server-scms136","server-sccp131","server-sccp132","server-sccp133","server-sccp134","server-sccp135","server-scwk131","server-scwk132")
    $portalServers = @("server-sccp131","server-sccp132","server-sccp133","server-sccp134","server-sccp135")
    $limit = (Get-Date).AddDays(-29)

    foreach ($server in $scsmServers)
        {
        $path = "\\$server\E$\Logging\"
            Get-ChildItem -Path $path -Recurse -Force | Where-Object { !$_.PSIsContainer -and $_.CreationTime -lt $limit } | Remove-Item -Force
        }

    foreach ($server in $portalServers)
        {
        $path = "\\$server\C$\inetpub\logs\LogFiles\"
            Get-ChildItem -Path $path -Recurse -Force | Where-Object { !$_.PSIsContainer -and $_.CreationTime -lt $limit } | Remove-Item -Force
        }

    foreach ($server in $portalServers)
        {
        $path = "\\$server\C$\ProgramData\Cireson.Platform.Host\"
            Get-ChildItem -Path $path -Force | Where-Object { !$_.PSIsContainer -and $_.CreationTime -lt $limit } | Remove-Item -Force
        }

    foreach ($server in $portalServers)
        {
        $path = "\\$server\C$\inetpub\CiresonPortal\Logs\"
            Get-ChildItem -Path $path -Force | Where-Object { !$_.PSIsContainer -and $_.CreationTime -lt $limit } | Remove-Item -Force
        }


Answers

  • Brian_WiestBrian_Wiest Customer Super IT Monkey ✭✭✭✭✭
    Answer ✓
    If at all interested here is a script for keeping the environment "clean".
    Couple notes.
    All Workflow logging from SCSM/Cireson (ie Notify Analyst logging and Asset Import) I have going to the local server E:\Logging\[Workflow Name]
    Also I have a weekly script that runs in the middle of the night that stops all SCSM services and the portal. I have it rename the webconsole.log and cachebuilder.log so the size doesn't balloon on me. (Which it has in the past)
    Make note of the -Recurse on some paths vs others. Some of the Cireson paths have files in nested folders that need to remain.
    This is setup via daily task manager. Helps make use I don't run out of file space just for logging files.
    HTH

    $scsmServers = @("server-scms131","server-scms132","server-scms133","server-scms134","server-scms135","server-scms136","server-sccp131","server-sccp132","server-sccp133","server-sccp134","server-sccp135","server-scwk131","server-scwk132")
    $portalServers = @("server-sccp131","server-sccp132","server-sccp133","server-sccp134","server-sccp135")
    $limit = (Get-Date).AddDays(-29)

    foreach ($server in $scsmServers)
        {
        $path = "\\$server\E$\Logging\"
            Get-ChildItem -Path $path -Recurse -Force | Where-Object { !$_.PSIsContainer -and $_.CreationTime -lt $limit } | Remove-Item -Force
        }

    foreach ($server in $portalServers)
        {
        $path = "\\$server\C$\inetpub\logs\LogFiles\"
            Get-ChildItem -Path $path -Recurse -Force | Where-Object { !$_.PSIsContainer -and $_.CreationTime -lt $limit } | Remove-Item -Force
        }

    foreach ($server in $portalServers)
        {
        $path = "\\$server\C$\ProgramData\Cireson.Platform.Host\"
            Get-ChildItem -Path $path -Force | Where-Object { !$_.PSIsContainer -and $_.CreationTime -lt $limit } | Remove-Item -Force
        }

    foreach ($server in $portalServers)
        {
        $path = "\\$server\C$\inetpub\CiresonPortal\Logs\"
            Get-ChildItem -Path $path -Force | Where-Object { !$_.PSIsContainer -and $_.CreationTime -lt $limit } | Remove-Item -Force
        }


  • Justin_WorkmanJustin_Workman Cireson Support Super IT Monkey ✭✭✭✭✭
    This is awesome @Brian_Wiest! Thanks for sharing your script!  I would recommend doing something similar to anyone who has the portal and/or Notify Analyst installed. 

    To clarify, are you using Task Scheduler on the server or some other method of running the script?
  • Brian_WiestBrian_Wiest Customer Super IT Monkey ✭✭✭✭✭
    Windows server task scheduler.  Setup to run the PS nightly using a service account that has admin rights to each target server.
Sign In or Register to comment.