longmem logs command displays recent log entries from the memory daemon.
Syntax
Options
| Option | Alias | Description | Default |
|---|---|---|---|
--lines <n> | -n | Number of lines to show | 50 |
--follow | -f | Follow log output (tail -f) | false |
--help | -h | Show help message | - |
Examples
View Last 50 Lines (Default)
View Last 100 Lines
Follow Logs in Real-Time
Ctrl+C to stop following.
Combine Options
--follow, the --lines option is ignored (it follows from the current end of file).
Log File Location
Logs are stored at:Output
No Logs Available
- Daemon has never been started
- Log file was deleted
- Daemon hasn’t written any logs yet
Normal Log Output
Log Format
Each log line typically includes:What to Look For
Startup Messages
Warnings
Compression Activity
Errors
Shutdown
Common Log Patterns
Healthy Operation
API Key Issues
Rate Limiting
Database Locks
Port Conflicts
Filtering Logs
Use standard Unix tools to filter logs:Show Only Errors
Show Compression Activity
Show Recent Errors
Count Error Occurrences
Log Rotation
Currently, LongMem does not automatically rotate logs. Thedaemon.log file will grow indefinitely.
To manually rotate:
Troubleshooting
Log file is huge
Cannot read log file
Logs show nothing recent
If logs stop updating:Exit Codes
0- Logs displayed successfully or no logs found1- Error reading log file
Related Commands
longmem status- Check daemon statuslongmem start- Start daemonlongmem stop- Stop daemon