> For the complete documentation index, see [llms.txt](https://docs.pharos.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.pharos.ai/platform-overview/pharos-platform-architecture/logs/log-storage/storage-usage.md).

# Storage Usage

Understand data storage usage, file storage usage, and log volumes.

Monitoring storage usage is essential for maintaining a healthy Pharos deployment. This guide explains how to track storage consumption, understand log volumes, and plan for capacity needs.

## Overview

Pharos stores data in your Salesforce org as custom objects, consuming **Data Storage** from your org's allocation. Understanding your storage usage helps you ensure sufficient capacity for ongoing operations and plan retention policies that make sense for your organization.

**Why monitoring matters:**

| Benefit                     | Impact                                                       |
| --------------------------- | ------------------------------------------------------------ |
| **Prevent Capacity Issues** | Avoid hitting storage limits that block new logs             |
| **Identify Trends**         | Spot error rate increases indicating new problems            |
| **Inform Decisions**        | Data-driven choice: purchase storage vs. implement retention |
| **Plan Proactively**        | Address issues before they become urgent                     |

{% hint style="info" %}
**Quick Check:** Navigate to **Setup → Storage Usage** in Salesforce to see your current Data Storage consumption and Pharos's contribution.
{% endhint %}

## Checking Storage Usage

### Salesforce Setup

**To view current storage consumption:**

1. Navigate to **Setup** in Salesforce
2. Quick Find → search for **"Storage Usage"**
3. Select **Storage Usage** from results

**The Storage Usage page displays:**

| Storage Type           | What It Shows                         | Why It Matters                    |
| ---------------------- | ------------------------------------- | --------------------------------- |
| **Data Storage**       | Total GB, % used, breakdown by object | Primary concern for Pharos logs   |
| **File Storage**       | Total GB, % used, breakdown           | Rarely impacted by Pharos         |
| **Big Object Storage** | Records used, available capacity      | For archived logs (if configured) |

### Storage Breakdown

The Storage Usage page shows what's consuming storage across your org:

**What you'll see:**

* Standard objects (Accounts, Contacts, Opportunities, etc.)
* Custom objects (including Pharos objects with namespace prefix)
* Other components (Files, Documents, etc.)

**Finding Pharos data:**

Look for custom objects with the **Pharos namespace prefix** in the breakdown table.

| Deployment Stage  | Visibility                      | Typical Consumption      |
| ----------------- | ------------------------------- | ------------------------ |
| **First 30 days** | May not appear in top consumers | < 100 MB                 |
| **Months 1-6**    | Appears lower in breakdown      | 100 MB - 1 GB            |
| **6+ months**     | More prominent position         | 1 GB+ (varies by volume) |

### Storage Types Explained

| Storage Type           | What Counts                                                     | Pharos Impact                                                          | Allocation                                                            |
| ---------------------- | --------------------------------------------------------------- | ---------------------------------------------------------------------- | --------------------------------------------------------------------- |
| **Data Storage**       | <p>• Log records<br>• Issue records<br>• Configuration data</p> | <p><strong>Primary impact</strong><br>All active Pharos data</p>       | <p>Varies by SF edition<br>Can purchase more<br>Shared across org</p> |
| **File Storage**       | <p>• Attachments<br>• Documents<br>• Large files</p>            | <p><strong>Minimal/None</strong><br>Only if large attachments used</p> | Usually unaffected                                                    |
| **Big Object Storage** | <p>• Archived logs<br>• Historical records</p>                  | <p><strong>Optional</strong><br>Only if archival configured</p>        | <p>1M records free<br>Can purchase more<br>Separate allocation</p>    |

{% hint style="success" %}
**Good News:** Most Pharos deployments only impact Data Storage. File Storage and Big Objects remain untouched unless you explicitly configure archival or store attachments.
{% endhint %}

## Understanding Log Volumes

### Factors Influencing Volume

Log volumes vary significantly based on interconnected factors in your Salesforce environment:

| Factor Category     | Drivers                                                                                                                                    | Impact on Volume                 |
| ------------------- | ------------------------------------------------------------------------------------------------------------------------------------------ | -------------------------------- |
| **Org Complexity**  | <p>• Automations (flows, triggers, processes)<br>• Custom code complexity<br>• Integration points<br>• Business process sophistication</p> | Higher complexity = more logs    |
| **Error Rates**     | <p>• Configuration issues<br>• Data quality problems<br>• Integration failures<br>• Code bugs or edge cases</p>                            | More errors = more logs          |
| **Activity Levels** | <p>• User count and activity<br>• Batch job frequency<br>• Integration transaction volume<br>• Peak usage periods</p>                      | Higher activity = more logs      |
| **Instrumentation** | <p>• Triton logging usage<br>• Debug vs. error-only logging<br>• Log level configuration</p>                                               | More instrumentation = more logs |

### Typical Volume Patterns

| Org Profile          | Logs/Day    | Storage/Year      | Retention Strategy                 |
| -------------------- | ----------- | ----------------- | ---------------------------------- |
| **Low Volume**       | 10-100      | \~18-90 MB        | No retention needed for years      |
| **Medium Volume**    | 100-1,000   | \~365 MB - 900 MB | Consider retention after 1-2 years |
| **High Volume**      | 1,000-5,000 | \~1.8-9 GB        | Proactive retention recommended    |
| **Very High Volume** | 5,000+      | 9+ GB             | Aggressive retention + archival    |

### Monitoring Trends

Tracking log volumes over time provides valuable insights into your org's health:

| Trend Type            | What It Reveals            | Action                    |
| --------------------- | -------------------------- | ------------------------- |
| **Spikes**            | New problems or incidents  | Investigate immediately   |
| **Seasonal Patterns** | Normal cyclical variations | Recognize as expected     |
| **Improvement**       | Error reduction success    | Measure effectiveness     |
| **Growth**            | Org expansion impact       | Plan capacity needs       |
| **Anomalies**         | Configuration changes      | Review recent deployments |

## Storage Capacity Planning

### Current Usage Assessment

Follow these steps to assess and project your storage needs:

**Step 1: Baseline Measurement**

Check Setup → Storage Usage:

| Metric               | Where to Find               | Example              |
| -------------------- | --------------------------- | -------------------- |
| Current Data Storage | Total used / Total capacity | 45 GB / 100 GB (45%) |
| Pharos Contribution  | Breakdown table             | \~2 GB               |
| Time Period          | Days since Pharos install   | 60 days              |

**Step 2: Calculate Daily Consumption**

```
Daily Rate = Total Pharos Storage ÷ Days Active
Example: 2 GB ÷ 60 days = ~33 MB/day
```

**Step 3: Project Future Usage**

| Timeframe    | Formula                      | Example Projection             |
| ------------ | ---------------------------- | ------------------------------ |
| **6 months** | Current + (Daily Rate × 180) | 2 GB + (33 MB × 180) = \~8 GB  |
| **1 year**   | Current + (Daily Rate × 365) | 2 GB + (33 MB × 365) = \~14 GB |

### When to Take Action

**Storage health thresholds:**

| Usage Level | Status   | Recommended Action                       | Urgency |
| ----------- | -------- | ---------------------------------------- | ------- |
| **< 70%**   | Healthy  | Monitor quarterly, no action needed      | None    |
| **70-80%**  | Watch    | Plan retention strategy, monitor monthly | Low     |
| **80-90%**  | Concern  | Implement retention or purchase storage  | Medium  |
| **> 90%**   | Critical | Immediate action required                | High    |

### Storage Optimization Strategies

When storage becomes constrained, consider these approaches:

| Strategy                    | Implementation                      | When to Use               | Effort  |
| --------------------------- | ----------------------------------- | ------------------------- | ------- |
| **Retention Rules**         | Auto-delete old logs                | Storage > 70%             | Low     |
| **Archival to Big Objects** | Move old logs to cheaper storage    | Want to preserve history  | Low     |
| **Selective Capture**       | Focus on errors, not debug          | High volume environments  | Medium  |
| **Purchase Storage**        | Buy additional GB from Salesforce   | Budget available          | Instant |
| **Export Off-Platform**     | Extract with Data Loader or the API | Long-term archival needed | High    |

{% hint style="warning" %}
**Before Aggressive Cleanup:** Evaluate the business value of historical data for compliance, auditing, and trend analysis. Purchasing storage may be more cost-effective than losing valuable insights.
{% endhint %}

## Monitoring Best Practices

### Regular Checks

Establish a monitoring cadence appropriate for your org:

| Org Type           | Check Frequency        | Why                           |
| ------------------ | ---------------------- | ----------------------------- |
| **New Deployment** | Weekly (first 90 days) | Establish baseline patterns   |
| **High Volume**    | Weekly                 | Catch issues early            |
| **Medium Volume**  | Bi-weekly              | Balance attention with effort |
| **Low Volume**     | Monthly                | Sufficient for stable orgs    |

### What to Monitor

Track both storage and log metrics:

| Category            | Metrics                                                                                  | Purpose           |
| ------------------- | ---------------------------------------------------------------------------------------- | ----------------- |
| **Storage Metrics** | <p>• Overall % used<br>• Pharos consumption<br>• Growth rate (MB/day or GB/month)</p>    | Capacity planning |
| **Log Metrics**     | <p>• Logs per day<br>• Issues per day<br>• Average log size<br>• Storage by category</p> | Volume trending   |
| **Anomalies**       | <p>• Sudden spikes<br>• Pattern changes<br>• Unexpected growth</p>                       | Problem detection |

### Setting Alerts

Proactive alerts prevent emergencies:

| Alert Type            | Threshold            | Purpose             | Action                  |
| --------------------- | -------------------- | ------------------- | ----------------------- |
| **Capacity Warning**  | 80% storage used     | Early warning       | Plan retention strategy |
| **Volume Spike**      | 2x normal daily logs | Problem detection   | Investigate cause       |
| **Growth Projection** | Exceed planned rate  | Planning adjustment | Revise capacity plan    |

{% hint style="info" %}
**Pro Tip:** Add storage monitoring to your regular Salesforce admin checklist. Consistent monitoring is more valuable than perfect frequency.
{% endhint %}

{% hint style="info" %}
**Tip**: Add storage monitoring to your regular Salesforce admin checklist alongside other health check items.
{% endhint %}

## Storage Usage Examples

Real-world scenarios to help estimate your org's storage needs:

### Example 1: Small Org

| Characteristic     | Details                                         |
| ------------------ | ----------------------------------------------- |
| **Profile**        | 50 users, moderate automation, few integrations |
| **Daily Volume**   | 10-50 logs → 50-250 KB/day                      |
| **Annual Impact**  | \~18-90 MB/year                                 |
| **Org Impact**     | Negligible                                      |
| **Recommendation** | ✅ No retention needed - keep all history        |

### Example 2: Medium Org

| Characteristic     | Details                                                    |
| ------------------ | ---------------------------------------------------------- |
| **Profile**        | 200 users, extensive flows, multiple integrations          |
| **Daily Volume**   | 200-500 logs → 1-2.5 MB/day                                |
| **Annual Impact**  | \~365-900 MB/year                                          |
| **Org Impact**     | Moderate                                                   |
| **Recommendation** | ⚠️ Monitor 3-6 months, implement retention after 1-2 years |

### Example 3: Large Org

| Characteristic     | Details                                                          |
| ------------------ | ---------------------------------------------------------------- |
| **Profile**        | 1,000+ users, complex code, heavy integrations                   |
| **Daily Volume**   | 1,000-5,000 logs → 5-25 MB/day                                   |
| **Annual Impact**  | \~1.8-9 GB/year                                                  |
| **Org Impact**     | Significant                                                      |
| **Recommendation** | 🔴 Proactive retention + Big Object archival + weekly monitoring |

## Storage and Performance

### Performance Considerations

Storage levels impact org performance:

| Storage Level | Performance | User Experience               | Recommendations           |
| ------------- | ----------- | ----------------------------- | ------------------------- |
| **< 80%**     | Optimal     | Standard response times       | Maintain this level       |
| **80-90%**    | Degrading   | Queries may slow              | Implement retention soon  |
| **> 90%**     | Poor        | Noticeable delays, throttling | Immediate action required |

{% hint style="warning" %}
**Performance Impact:** High storage consumption (>80%) can slow queries and trigger Salesforce throttling. Managing storage is about performance, not just capacity.
{% endhint %}

### Optimizing for Performance

Best practices for maintaining query performance:

| Practice                           | Implementation                | Benefit                     |
| ---------------------------------- | ----------------------------- | --------------------------- |
| **Active Data in Custom Objects**  | Keep recent logs accessible   | Fast query response         |
| **Historical Data in Big Objects** | Archive old logs              | Reduces active dataset size |
| **Selective Queries**              | Always use WHERE clauses      | Limits rows scanned         |
| **Leverage Indexes**               | Use indexed fields in filters | Dramatically faster queries |

## Taking Action on Storage

### When Storage is Abundant (< 70%)

**Recommended approach:**

| Action                        | Why                                |
| ----------------------------- | ---------------------------------- |
| **Keep all historical data**  | Enables year-over-year comparisons |
| **No retention rules needed** | Maximize analytical value          |
| **Focus on insights**         | Use data for root cause analysis   |
| **Monitor quarterly**         | Maintain awareness without urgency |

**Benefits of keeping data:**

* Year-over-year trend analysis
* Complete historical record for compliance
* Better root cause investigations
* Organizational learning from past issues

### When Storage is Constrained (> 80%)

**Immediate action steps:**

| Step | Action                       | Tool/Location                  |
| ---- | ---------------------------- | ------------------------------ |
| 1    | Assess current usage         | Setup → Storage Usage          |
| 2    | Identify Pharos contribution | Storage breakdown table        |
| 3    | Determine retention period   | Based on available space       |
| 4    | Implement retention rules    | Pharos Admin → Retention       |
| 5    | Monitor effectiveness        | Weekly checks until stabilized |

**Strategic decisions:**

| Option                  | Cost              | Benefit             | When to Choose                    |
| ----------------------- | ----------------- | ------------------- | --------------------------------- |
| **Purchase Storage**    | $ per GB          | Keep all data       | Budget available, high data value |
| **Big Object Archival** | Free (1M records) | Preserve history    | Want long-term access             |
| **Export Off-Platform** | Extraction effort | Unlimited retention | Compliance requirements           |
| **Retention Rules**     | Free              | Reduce footprint    | Low historical value              |

{% hint style="warning" %}
**Cost-Benefit Analysis:** Before aggressive retention, calculate: Is purchasing 10 GB storage cheaper than losing 2 years of historical data for trend analysis and compliance?
{% endhint %}

## Storage FAQs

| Question                                        | Answer                                                                                                               |
| ----------------------------------------------- | -------------------------------------------------------------------------------------------------------------------- |
| **How much storage does Pharos typically use?** | Varies widely: Small org (18-90 MB/year), Medium org (365-900 MB/year), Large org (1.8-9 GB/year)                    |
| **Does Pharos consume File Storage?**           | Typically no. Only uses Data Storage unless large attachments are configured                                         |
| **What is Big Object Storage?**                 | Separate storage tier for archival (1M records free per org). Pharos can archive old logs there to free Data Storage |
| **How do I know if storage is a problem?**      | Check Setup → Storage Usage. Action needed if >80% capacity                                                          |
| **Can I delete Pharos data?**                   | Yes, via manual deletion or retention rules. Consider archiving first to preserve history                            |
| **Will retention rules delete issues?**         | No, only log records. Issues persist to preserve historical record                                                   |
| **How often should I check storage?**           | New/high-volume: weekly. Established/low-volume: monthly                                                             |
| **What if I'm near capacity?**                  | Options: (1) Purchase storage, (2) Archive to Big Objects, (3) Implement retention rules                             |
