2017-12-21 22:00:34 +01:00
|
|
|
# Linux OOMAnalyser
|
2017-11-25 12:52:55 +01:00
|
|
|
|
|
|
|
I've started this project to give the Python to JavaScript compiler
|
|
|
|
[Transcrypt](https://www.transcrypt.org/) a try.
|
|
|
|
|
|
|
|
This web page splits the content of a Linux Out Of Memory message into
|
|
|
|
smaller pieces, aggregates these and presents them in a more human friendly
|
|
|
|
format.
|
|
|
|
|
2017-11-25 13:14:54 +01:00
|
|
|
You can use the current version on [www.carstengrohmann.de/oom/](https://www.carstengrohmann.de/oom/).
|
|
|
|
|
2017-11-25 12:52:55 +01:00
|
|
|
## Design Goals
|
|
|
|
* A local copy of the web page should run offline - without an Internet
|
|
|
|
connection, without loading 3rd party libraries nor transferring data to
|
|
|
|
foreign servers
|
|
|
|
* A better understanding of the Linux Memory Management
|
|
|
|
* Start learning JavaScript, CSS and HTML
|
|
|
|
|
2017-12-21 22:00:34 +01:00
|
|
|
## Build and Installation
|
|
|
|
|
|
|
|
This section describes a manual build and installation of OOMAnalyser.
|
|
|
|
|
|
|
|
### Requirements
|
|
|
|
|
2017-11-25 12:52:55 +01:00
|
|
|
* [Python](http://www.python.org) 3.6 or later
|
|
|
|
* [Transcrypt](https://www.transcrypt.org/) 3.6.53 or later
|
|
|
|
|
2017-12-21 22:00:34 +01:00
|
|
|
### Setup
|
|
|
|
Clone the repository:
|
2017-11-25 12:52:55 +01:00
|
|
|
```
|
2017-12-21 22:00:34 +01:00
|
|
|
# git clone https://github.com/CarstenGrohmann/OOMAnalyser
|
2017-11-25 12:52:55 +01:00
|
|
|
```
|
|
|
|
|
2017-12-21 22:00:34 +01:00
|
|
|
Setup the Python virtual environment:
|
2017-11-25 12:52:55 +01:00
|
|
|
```
|
|
|
|
# virtualenv env
|
|
|
|
# . env/bin/activate
|
|
|
|
# env/bin/pip install -Ur requirements.txt
|
|
|
|
|
2017-12-21 22:00:34 +01:00
|
|
|
or
|
|
|
|
|
2017-11-25 12:52:55 +01:00
|
|
|
# make venv
|
|
|
|
```
|
|
|
|
|
2017-12-21 22:00:34 +01:00
|
|
|
### Build
|
2017-11-25 12:52:55 +01:00
|
|
|
```
|
|
|
|
# . env/bin/activate
|
|
|
|
# transcrypt --build --map --nomin -e 6 OOMAnalyser.py
|
2017-12-21 22:00:34 +01:00
|
|
|
|
|
|
|
or
|
|
|
|
|
|
|
|
# make build
|
2017-11-25 12:52:55 +01:00
|
|
|
```
|
|
|
|
|
2017-12-21 22:00:34 +01:00
|
|
|
## Usage
|
|
|
|
* Change into the source directory and start your own small web server.
|
|
|
|
|
|
|
|
* Start Python built-in web server:
|
|
|
|
|
|
|
|
* ```
|
|
|
|
# python3 -m http.server 8080 --bind 127.0.0.1
|
|
|
|
|
|
|
|
or
|
|
|
|
|
|
|
|
# make websrv
|
|
|
|
```
|
|
|
|
|
|
|
|
* Open the URL [http://localhost:8080/OOMAnalyser.html](http://localhost:8080/OOMAnalyser.html) in your favorite browser.
|
|
|
|
|
|
|
|
* That's it!
|
|
|
|
|
2017-11-25 12:52:55 +01:00
|
|
|
## Further Information
|
2017-12-21 22:00:34 +01:00
|
|
|
* [Transcrypt](https://www.transcrypt.org/)
|
2017-11-25 12:52:55 +01:00
|
|
|
* [Linux man pages online](https://man7.org/)
|
|
|
|
* [Decoding the Linux kernel's page allocation failure messages](https://utcc.utoronto.ca/~cks/space/blog/linux/DecodingPageAllocFailures)
|
|
|
|
* [Linux Kernel OOM Log Analysis](http://elearningmedium.com/linux-kernel-oom-log-analysis/)
|
|
|
|
|
|
|
|
## Known Bugs/Issues
|
|
|
|
|
|
|
|
Check the bug tracker on [GitHub](https://github.com/CarstenGrohmann/OOMAnalyser/issues) for current open bugs.
|
|
|
|
New bugs can be reported there also.
|
|
|
|
|
|
|
|
## License
|
2017-12-21 22:00:34 +01:00
|
|
|
This project is licensed under the MIT license.
|
|
|
|
|
2017-11-25 12:52:55 +01:00
|
|
|
```
|
2018-04-06 21:56:29 +02:00
|
|
|
Copyright (c) 2017-2018 Carsten Grohmann, mail <add at here> carsten-grohmann.de
|
2017-11-25 12:52:55 +01:00
|
|
|
|
|
|
|
Permission is hereby granted, free of charge, to any person obtaining a copy of
|
|
|
|
this software and associated documentation files (the "Software"), to deal in
|
|
|
|
the Software without restriction, including without limitation the rights to
|
|
|
|
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
|
|
|
|
of the Software, and to permit persons to whom the Software is furnished to do
|
|
|
|
so, subject to the following conditions:
|
|
|
|
|
|
|
|
The above copyright notice and this permission notice shall be included in all
|
|
|
|
copies or substantial portions of the Software.
|
|
|
|
|
|
|
|
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
|
|
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
|
|
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
|
|
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
|
|
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
|
|
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
|
|
SOFTWARE.
|
|
|
|
```
|
|
|
|
|
|
|
|
Enjoy!
|
2017-12-21 22:00:34 +01:00
|
|
|
Carsten Grohmann
|