Giter VIP home page Giter VIP logo

Comments (18)

negbie avatar negbie commented on July 27, 2024

Hi @y0tsawin could you show me the output of ls -al /opt/fancy

from fancy.

negbie avatar negbie commented on July 27, 2024

You need to make sure that rsyslog has the permissions to execute it.

from fancy.

y0tsawin avatar y0tsawin commented on July 27, 2024

ls -al /opt/fancy
total 80
drwxr-xr-x 5 root root 4096 Oct 29 15:56 .
drwxr-xr-x 5 root root 4096 Oct 29 15:56 ..
drwxr-xr-x 4 root root 4096 Oct 29 15:56 example
drwxr-xr-x 8 root root 4096 Oct 29 15:56 .git
-rwxr-xr-x 1 root root 267 Oct 29 15:56 go.mod
-rwxr-xr-x 1 root root 8366 Oct 29 15:56 go.sum
-rwxr-xr-x 1 root root 11343 Oct 29 15:56 LICENSE
-rwxr-xr-x 1 root root 823 Oct 29 15:56 logline.go
drwxr-xr-x 2 root root 4096 Oct 29 15:56 logproto
-rwxr-xr-x 1 root root 4361 Oct 29 15:56 loki.go
-rwxr-xr-x 1 root root 4793 Oct 29 15:56 main.go
-rwxr-xr-x 1 root root 1456 Oct 29 15:56 parse.go
-rwxr-xr-x 1 root root 1650 Oct 29 15:56 parse_test.go
-rwxr-xr-x 1 root root 1259 Oct 29 15:56 README.md

from fancy.

negbie avatar negbie commented on July 27, 2024

/opt/fancy is in your case a directory but omprog expects the binary there.

from fancy.

y0tsawin avatar y0tsawin commented on July 27, 2024

binary="/opt/fancy --loki-url http://192.168.0.122:3100"
Can you recommend. How do I have to config omprog ?

from fancy.

negbie avatar negbie commented on July 27, 2024

Just make sure the fancy binary is in /opt
So when you run ls -al /opt/fancy you should see something like this:
-rwxr-xr-x 1 negbie negbie 3311828 Oct 27 21:07 /opt/fancy

In rsyslog.conf you can set this:

action(type="omprog" name="fancy" template="fancy" output="/var/log/fancy.log" binary="/opt/fancy --loki-url http://192.168.0.122:3100")

from fancy.

negbie avatar negbie commented on July 27, 2024

But you have downloaded the binary from releases https://github.com/negbie/fancy/releases right?

from fancy.

negbie avatar negbie commented on July 27, 2024

Btw. I have uploaded a rsyslog.conf example too here: https://github.com/negbie/fancy/blob/master/example/rsyslog/rsyslog.conf

from fancy.

negbie avatar negbie commented on July 27, 2024

Would you say my setup guide here https://github.com/negbie/fancy#setup is not clear enough and I should improve it?

from fancy.

y0tsawin avatar y0tsawin commented on July 27, 2024

I have done as you suggest.

ls -al
-rwxr-xr-x 1 root root 3311812 Oct 27 04:24 fancy

rsysconf.conf
module(load="omprog")
$template fancy,"%syslogseverity% %hostname% %programname%%msg%\n"
action(type="omprog" name="fancy" template="fancy" output="/var/log/fancy.log" binary="/opt/fancy --loki-url http://192.168.1.122:3100")

from fancy.

negbie avatar negbie commented on July 27, 2024

Good, do you still need help?

from fancy.

y0tsawin avatar y0tsawin commented on July 27, 2024

Can I use this file instead of the original file?

https://github.com/negbie/fancy/blob/master/example/rsyslog/rsyslog.conf

from fancy.

negbie avatar negbie commented on July 27, 2024

You will need to make some adjustments but basicly yes.

from fancy.

negbie avatar negbie commented on July 27, 2024

@y0tsawin Do you still need help or can I close this issue?

from fancy.

negbie avatar negbie commented on July 27, 2024

@y0tsawin attention, version 1.6 is up and requires a different template. Please see readme.

from fancy.

negbie avatar negbie commented on July 27, 2024

New template should look like this for version 1.6:

$template fancy,"%timegenerated:::date-rfc3339% %syslogseverity% %hostname% %programname%%msg%\n"

from fancy.

y0tsawin avatar y0tsawin commented on July 27, 2024

Good. It work.
Thank you for your support.

from fancy.

negbie avatar negbie commented on July 27, 2024

Your welcome. Don't forget to give this project a start if you like it. It's the best way to say thank you to a project on github.

from fancy.

Related Issues (4)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.