Syslog-ng truncates lines when writing to output log - syslog-ng

OS: SLes 11 sp4
syslog-ng: syslog-ng-2.0.9-27.34.39.2
Hi,
syslog-ng is configured to read from a application log file and then send it to another file in /var/log (tcpdump is not installed, I cant install it on a blackbox so this is how I test my config)
I have the following in my syslog-ng configuration file:
source ESRS {
file("/opt/esrsve/gateway/xGate.log");
};
destination esrsfile{ file("/var/log/max.log" );};
log { source(ESRS);
destination(esrsfile);
};
The problem I am seeing is that when syslog writes to the outputfile (esrsfile) it truncatedthe lines.
ex: Source File :
[ 0, 6, 1, 1007] 08-29-2016 13:56:28.703 IMPORTANT INFO EDDEMC: Data Item::PMStatus Current Value::Offline
And the destination file looiks like this:
...
...
Aug 29 14:00:02 hostname C
Aug 29 14:00:02 hostname u
Aug 29 14:00:02 hostname r
Aug 29 14:00:02 hostname r
Aug 29 14:00:02 hostname e
Aug 29 14:00:02 hostname n
Aug 29 14:00:02 hostname t
Aug 29 14:00:02 hostname
Aug 29 14:00:02 hostname V
Aug 29 14:00:02 hostname a
Aug 29 14:00:02 hostname l
Aug 29 14:00:02 hostname u
Aug 29 14:00:02 hostname e
Aug 29 14:00:02 hostname :
Aug 29 14:00:02 hostname :
Aug 29 14:00:02 hostname O
Aug 29 14:00:02 hostname f
Aug 29 14:00:02 hostname f
Aug 29 14:00:02 hostname l
Aug 29 14:00:02 hostname i
Aug 29 14:00:02 hostname n
Aug 29 14:00:02 hostname e
...
...
What is wrong here please?

When you look closely, the lines are not truncated, but one log entry spreads over multiple lines, character by character. It happens usually, when the log writer flushes after writing every single character.
Make sure the writer buffers lines and sends them as one single message.

Related

Indexing Time in Redshift

i have a dataset with that has sales by month and a column for when an promotion happens for a number of products.
i want to index the months so that i can compare the different products over a pre and post 12m period easily
this is the data i have
Date
sales.
Promo?
Jan 21
100
Feb 21
110.
Mar 21
100.
apr 21
110.
may 21
90.
jun 21
100.
jul 21
120.
aug 21
140.
X
sep 21
100.
oct 21
90.
nov 21
100.
dec 21
120.
jan 22
110.
feb 22
100
this is what i want
can someone tell me how to do this in redshift?
Date
sales.
Promo?
month index
Jan 21
100
-7.
Feb 21
110.
-6
Mar 21
100.
-5
apr 21
110.
-4
may 21
90.
-3
jun 21
100.
-2
jul 21
120.
-1
aug 21
140.
X
0
sep 21
100.
1
oct 21
90.
2
nov 21
100.
3
dec 21
120.
4
jan 22
110.
5
feb 22
100
6

Redis Time Series Module Not Loading

I'm new to Redis and would like to play with the RedisTimeSeries module. Following the instructions I load the module using:
redis-server --loadmodule /path/to/module/redistimeseries.so
Obviously adjusting the path to match mine. The server starts and shows the following output:
88537:M 02 Apr 2022 12:19:24.785 # Server initialized
88537:M 02 Apr 2022 12:19:24.789 * <timeseries> RedisTimeSeries version 10609, git_sha=f36e5a703dc9a2487880087a34f6cb0e56d9a459
88537:M 02 Apr 2022 12:19:24.789 * <timeseries> Redis version found by RedisTimeSeries : 6.2.6 - oss
88537:M 02 Apr 2022 12:19:24.789 * <timeseries> loaded default CHUNK_SIZE_BYTES policy: 4096
88537:M 02 Apr 2022 12:19:24.789 * <timeseries> loaded server DUPLICATE_POLICY: block
88537:M 02 Apr 2022 12:19:24.789 * <timeseries> Setting default series ENCODING to: compressed
88537:M 02 Apr 2022 12:19:24.789 * <timeseries> Detected redis oss
88537:M 02 Apr 2022 12:19:24.789 * <timeseries> Enabled diskless replication
88537:M 02 Apr 2022 12:19:24.789 * Module 'timeseries' loaded from lib/redistimeseries.so
88537:M 02 Apr 2022 12:19:24.790 * Loading RDB produced by version 6.2.6
88537:M 02 Apr 2022 12:19:24.790 * RDB age 4 seconds
88537:M 02 Apr 2022 12:19:24.790 * RDB memory usage when created 1.02 Mb
88537:M 02 Apr 2022 12:19:24.790 # Done loading RDB, keys loaded: 0, keys expired: 0.
88537:M 02 Apr 2022 12:19:24.790 * DB loaded from disk: 0.000 seconds
88537:M 02 Apr 2022 12:19:24.790 * Ready to accept connections
When I connect using the redis-cli I run the sample command like so:
TS.CREATE temperature RETENTION 60 LABELS sensor_id 2 area_id 32
However, I receive the following error in the CLI:
(error) ERR unknown command `TS.CREATE`, with args beginning with: `temperature`, `RETENTION`, `60`, `LABELS`, `sensor_id`, `2`, `area_id`, `32`,
No time series commands are available. Can anyone help? I'm stumped.

cmake complains "Could NOT find X11 (missing: X11_X11_LIB)",but all x11 related stuff got installed already

I got this error in ubuntu 21.04
CMake Error at /usr/share/cmake-3.18/Modules/FindPackageHandleStandardArgs.cmake:165 (message):
Could NOT find X11 (missing: X11_X11_LIB)
Call Stack (most recent call first):
/usr/share/cmake-3.18/Modules/FindPackageHandleStandardArgs.cmake:458 (_FPHSA_FAILURE_MESSAGE)
/usr/lib/x86_64-linux-gnu/cmake/vtk-9.0/patches/99/FindX11.cmake:366 (find_package_handle_standard_args)
/usr/lib/x86_64-linux-gnu/cmake/vtk-9.0/VTK-vtk-module-find-packages.cmake:209 (find_package)
/usr/lib/x86_64-linux-gnu/cmake/vtk-9.0/vtk-config.cmake:131 (include)
but all x11 related stuff got installed already by
sudo apt install libx11*
I can find related includes and libs in their location:
alex#x-space:~/workspace/Scene/Debug$ sudo locate libX11
/usr/lib/i386-linux-gnu/libX11-xcb.so.1
/usr/lib/i386-linux-gnu/libX11-xcb.so.1.0.0
/usr/lib/i386-linux-gnu/libX11.so.6
/usr/lib/i386-linux-gnu/libX11.so.6.4.0
/usr/lib/x86_64-linux-gnu/libX11-xcb.so.1
/usr/lib/x86_64-linux-gnu/libX11-xcb.so.1.0.0
/usr/lib/x86_64-linux-gnu/libX11.a
/usr/lib/x86_64-linux-gnu/libX11.so
/usr/lib/x86_64-linux-gnu/libX11.so.6
/usr/lib/x86_64-linux-gnu/libX11.so.6.4.0
alex#x-space:~/workspace/Scene/Debug$ lh /usr/include/X11/
total 1.1M
-rw-r--r-- 1 root root 2.3K Apr 15 2020 ap_keysym.h
drwxr-xr-x 2 root root 4.0K Apr 20 18:48 bitmaps
-rw-r--r-- 1 root root 4.0K Aug 17 2020 CallbackI.h
-rw-r--r-- 1 root root 3.5K Aug 17 2020 Composite.h
-rw-r--r-- 1 root root 4.7K Aug 17 2020 CompositeP.h
-rw-r--r-- 1 root root 4.0K Aug 17 2020 ConstrainP.h
-rw-r--r-- 1 root root 2.6K Aug 17 2020 Constraint.h
-rw-r--r-- 1 root root 3.4K Aug 17 2020 ConvertI.h
-rw-r--r-- 1 root root 2.6K Aug 17 2020 Core.h
-rw-r--r-- 1 root root 8.4K Aug 17 2020 CoreP.h
-rw-r--r-- 1 root root 1.4K Aug 17 2020 CreateI.h
-rw-r--r-- 1 root root 3.1K May 20 01:00 cursorfont.h
-rw-r--r-- 1 root root 2.8K Apr 15 2020 DECkeysym.h
drwxr-xr-x 2 root root 4.0K Sep 14 21:02 dri
-rw-r--r-- 1 root root 4.2K Aug 17 2020 EventI.h
drwxr-xr-x 2 root root 4.0K Sep 30 18:01 extensions
drwxr-xr-x 2 root root 4.0K Sep 30 15:59 fonts
-rw-r--r-- 1 root root 2.2K Aug 17 2020 HookObjI.h
-rw-r--r-- 1 root root 6.0K Apr 15 2020 HPkeysym.h
drwxr-xr-x 2 root root 4.0K Sep 14 21:04 ICE
-rw-r--r-- 1 root root 405 May 20 01:00 ImUtil.h
-rw-r--r-- 1 root root 13K Aug 17 2020 InitialI.h
-rw-r--r-- 1 root root 63K Aug 17 2020 Intrinsic.h
-rw-r--r-- 1 root root 6.8K Aug 17 2020 IntrinsicI.h
-rw-r--r-- 1 root root 9.5K Aug 17 2020 IntrinsicP.h
-rw-r--r-- 1 root root 172K Apr 15 2020 keysymdef.h
-rw-r--r-- 1 root root 2.8K Apr 15 2020 keysym.h
-rw-r--r-- 1 root root 2.6K Aug 17 2020 Object.h
-rw-r--r-- 1 root root 6.8K Aug 17 2020 ObjectP.h
-rw-r--r-- 1 root root 5.4K Aug 17 2020 PassivGraI.h
-rw-r--r-- 1 root root 2.6K Aug 17 2020 RectObj.h
-rw-r--r-- 1 root root 6.3K Aug 17 2020 RectObjP.h
-rw-r--r-- 1 root root 2.9K Aug 17 2020 ResConfigP.h
-rw-r--r-- 1 root root 3.7K Aug 17 2020 ResourceI.h
-rw-r--r-- 1 root root 5.1K Aug 17 2020 SelectionI.h
-rw-r--r-- 1 root root 18K Aug 17 2020 Shell.h
-rw-r--r-- 1 root root 212 Aug 17 2020 ShellI.h
-rw-r--r-- 1 root root 13K Aug 17 2020 ShellP.h
drwxr-xr-x 2 root root 4.0K Sep 14 21:04 SM
-rw-r--r-- 1 root root 30K Aug 17 2020 StringDefs.h
-rw-r--r-- 1 root root 4.0K Apr 15 2020 Sunkeysym.h
-rw-r--r-- 1 root root 4.2K Aug 17 2020 ThreadsI.h
-rw-r--r-- 1 root root 17K Aug 17 2020 TranslateI.h
-rw-r--r-- 1 root root 2.4K Aug 17 2020 VarargsI.h
-rw-r--r-- 1 root root 2.8K Aug 17 2020 Vendor.h
-rw-r--r-- 1 root root 3.5K Aug 17 2020 VendorP.h
-rw-r--r-- 1 root root 4.5K Apr 15 2020 Xalloca.h
-rw-r--r-- 1 root root 2.9K Apr 15 2020 Xarch.h
-rw-r--r-- 1 root root 2.5K Apr 15 2020 Xatom.h
-rw-r--r-- 1 root root 3.8K Feb 25 2021 Xauth.h
-rw-r--r-- 1 root root 21K May 20 01:00 Xcms.h
-rw-r--r-- 1 root root 2.4K Apr 15 2020 Xdefs.h
-rw-r--r-- 1 root root 6.3K Feb 25 2021 Xdmcp.h
-rw-r--r-- 1 root root 14K Apr 15 2020 XF86keysym.h
drwxr-xr-x 2 root root 4.0K Sep 14 21:59 Xft
-rw-r--r-- 1 root root 7.7K Apr 15 2020 Xfuncproto.h
-rw-r--r-- 1 root root 2.3K Apr 15 2020 Xfuncs.h
-rw-r--r-- 1 root root 20K Apr 15 2020 X.h
-rw-r--r-- 1 root root 31K May 20 01:00 XKBlib.h
-rw-r--r-- 1 root root 1.6K May 20 01:00 XlibConf.h
-rw-r--r-- 1 root root 98K May 20 01:00 Xlib.h
-rw-r--r-- 1 root root 40K May 20 01:00 Xlibint.h
-rw-r--r-- 1 root root 506 May 20 01:00 Xlib-xcb.h
-rw-r--r-- 1 root root 1.3K May 20 01:00 Xlocale.h
-rw-r--r-- 1 root root 5.1K Apr 15 2020 Xmd.h
drwxr-xr-x 2 root root 4.0K Sep 18 07:29 Xmu
-rw-r--r-- 1 root root 3.1K Apr 15 2020 Xosdefs.h
-rw-r--r-- 1 root root 4.3K Apr 15 2020 Xos.h
-rw-r--r-- 1 root root 33K Apr 15 2020 Xos_r.h
-rw-r--r-- 1 root root 7.6K Apr 15 2020 Xpoll.h
-rw-r--r-- 1 root root 52K Apr 15 2020 Xproto.h
-rw-r--r-- 1 root root 2.7K Apr 15 2020 Xprotostr.h
-rw-r--r-- 1 root root 5.9K May 20 01:00 Xregion.h
-rw-r--r-- 1 root root 11K May 20 01:00 Xresource.h
-rw-r--r-- 1 root root 13K Apr 15 2020 Xthreads.h
-rw-r--r-- 1 root root 2.9K Aug 17 2020 Xtos.h
drwxr-xr-x 2 root root 4.0K Sep 14 21:02 Xtrans
-rw-r--r-- 1 root root 21K May 20 01:00 Xutil.h
-rw-r--r-- 1 root root 1.9K Apr 15 2020 Xw32defs.h
-rw-r--r-- 1 root root 3.8K Apr 15 2020 XWDFile.h
-rw-r--r-- 1 root root 3.3K Apr 15 2020 Xwindows.h
-rw-r--r-- 1 root root 2.3K Apr 15 2020 Xwinsock.h
Why do I still get this error?

WAS not processing request hence web are not available

I'm new to supporting WAS (Websphere Application Server), currently I'm having issue with my WAS, my WAS was installed under AIX under 2 servers/nodes.
While investigating it, I found in our application log that there are some activity which is "Performing Cache Maintenance":
===================================
2017-01-14 01:31:52,619: [Cache Maintenance] com.ibm.srm.util.db.ServerCache refreshed 2017-01-14 01:31:53,314: [Cache Maintenance] Memory: available=[6884mb] used=[9500mb] %used avail=[58%] max=[16384mb] %used max=[58%] total=[16384mb] free=[6884mb] used by doMaintenance=[-251,201,3 92bytes] Time=[22,818ms] 2017-01-14 01:51:53,325: -------- Performing Cache Maintenance -------- 2017-01-14 01:51:53,325: null : QN=319 Select * from perform.cache_timestamps where row_class_name not like '%Cache' and row_class_name not like '%(SRM 6.0)' 2017-01-14 01:51:53,333: Returning 19 data records, QN=319,2 columns, Time: 8ms conn/query time: 5ms
2017-01-14 01:51:53,333: [Cache Maintenance] Memory: available=[5492mb] used=[10892mb] %used avail=[66%] max=[16384mb] %used max=[66%] total=[16384mb] free=[5492mb] used by doMaintenance=[532kb] Time=[8ms]
===================================
After this activity triggered, I found that mpmstats value for 'bsy' are keep increasing until reach MaxClient maximum value which is '4000':
===================================
[Sat Jan 14 01:38:58 2017] [notice] mpmstats: rdy 166 bsy 234 rd 0 wr 234 ka 0 log 0 dns 0 cls 0 [Sat Jan 14 01:38:58 2017] [notice] mpmstats: bsy: 234 in mod_was_ap22_http.c [Sat Jan 14 01:48:58 2017] [notice] mpmstats: rdy 195 bsy 505 rd 0 wr 505 ka 0 log 0 dns 0 cls 0 [Sat Jan 14 01:48:58 2017] [notice] mpmstats: bsy: 505 in mod_was_ap22_http.c [Sat Jan 14 01:58:58 2017] [notice] mpmstats: rdy 180 bsy 720 rd 0 wr 720 ka 0 log 0 dns 0 cls 0 [Sat Jan 14 01:58:58 2017] [notice] mpmstats: bsy: 720 in mod_was_ap22_http.c [Sat Jan 14 02:08:59 2017] [notice] mpmstats: rdy 105 bsy 895 rd 1 wr 894 ka 0 log 0 dns 0 cls 0 [Sat Jan 14 02:08:59 2017] [notice] mpmstats: bsy: 894 in mod_was_ap22_http.c [Sat Jan 14 02:18:59 2017] [notice] mpmstats: rdy 112 bsy 1088 rd 1 wr 1087 ka 0 log 0 dns 0 cls 0 [Sat Jan 14 02:18:59 2017] [notice] mpmstats: bsy: 1087 in mod_was_ap22_http.c
[Sat Jan 14 02:28:59 2017] [notice] mpmstats: rdy 158 bsy 1242 rd 1 wr 1241 ka 0 log 0 dns 0 cls 0
----
[Sat Jan 14 04:55:34 2017] [notice] mpmstats: rdy 0 bsy 4000 rd 0 wr 4000 ka 0 log 0 dns 0 cls 0 [Sat Jan 14 04:55:34 2017] [notice] mpmstats: bsy: 4000 in mod_was_ap22_http.c [Sat Jan 14 04:57:04 2017] [notice] mpmstats: reached MaxClients (4000/4000) [Sat Jan 14 04:57:04 2017] [notice] mpmstats: rdy 0 bsy 4000 rd 0 wr 4000 ka 0 log 0 dns 0 cls 0 [Sat Jan 14 04:57:04 2017] [notice] mpmstats: bsy: 4000 in mod_was_ap22_http.c [Sat Jan 14 04:58:34 2017] [notice] mpmstats: reached MaxClients (4000/4000) [Sat Jan 14 04:58:34 2017] [notice] mpmstats: rdy 0 bsy 4000 rd 0 wr 4000 ka 0 log 0 dns 0 cls 0
[Sat Jan 14 04:58:34 2017] [notice] mpmstats: bsy: 4000 in mod_was_ap22_http.c
===================================
It seem WAS are not processing the client request until it reached the Maximum value.
The questions are:
Is there any log that I can check about why WAS are not processing the Client request until it reached to the max value?
Does the "Cache Maintenance" activity hold WAS from processing the Client request? Because as mentioned from our developer this activity should not lead to this issue.
What is the procedure that I can take to identify/resolve this issue?
Appreciate if can help me for this thing as this issue already occurred for a long time but still not resolve.

Cacti 0.8.8a / CentOS 6.4 / ERROR: opening '/usr/share/cacti/rra/*.rrd': No such file or directory

I've just installed Cacti 0.8.8a from EPEL repo of CentOS 6.4. Everything is fine except the graphs do not show up. I checked the log of httpd then I see:
ERROR: opening '/usr/share/cacti/rra/localhost_mem_buffers_3.rrd': No such file or directory
ERROR: opening '/usr/share/cacti/rra/localhost_proc_7.rrd': No such file or directory
ERROR: opening '/usr/share/cacti/rra/localhost_users_6.rrd': No such file or directory
ERROR: opening '/usr/share/cacti/rra/localhost_load_1min_5.rrd': No such file or directory
Seems like rrdtool did not generate those files.
This is in /usr/share/cacti
ls -ls /usr/share/cacti
total 872
8 -rw-r--r-- 1 root root 5945 Jun 28 2012 about.php
8 -rw-r--r-- 1 root root 5348 Jun 28 2012 auth_changepassword.php
16 -rw-r--r-- 1 root root 14288 Jun 28 2012 auth_login.php
24 -rw-r--r-- 1 root root 21658 Jun 28 2012 cdef.php
0 lrwxrwxrwx 1 root root 18 Jul 25 13:42 cli -> /var/lib/cacti/cli
28 -rwxr-xr-x 1 root root 26620 Jun 28 2012 cmd.php
8 -rw-r--r-- 1 root root 6974 Jun 28 2012 color.php
28 -rw-r--r-- 1 root root 25068 Jun 28 2012 data_input.php
36 -rw-r--r-- 1 root root 35505 Jun 28 2012 data_queries.php
60 -rw-r--r-- 1 root root 60117 Jun 28 2012 data_sources.php
36 -rw-r--r-- 1 root root 32920 Jun 28 2012 data_templates.php
8 -rw-r--r-- 1 root root 6107 Jun 28 2012 gprint_presets.php
4 -rw-r--r-- 1 root root 3657 Jun 28 2012 graph_image.php
16 -rw-r--r-- 1 root root 13469 Jun 28 2012 graph.php
12 -rw-r--r-- 1 root root 9208 Jun 28 2012 graph_settings.php
20 -rw-r--r-- 1 root root 17426 Jun 28 2012 graphs_items.php
40 -rw-r--r-- 1 root root 40166 Jun 28 2012 graphs_new.php
60 -rw-r--r-- 1 root root 60571 Jun 28 2012 graphs.php
12 -rw-r--r-- 1 root root 10006 Jun 28 2012 graph_templates_inputs.php
20 -rw-r--r-- 1 root root 18542 Jun 28 2012 graph_templates_items.php
28 -rw-r--r-- 1 root root 26703 Jun 28 2012 graph_templates.php
40 -rw-r--r-- 1 root root 40313 Jun 28 2012 graph_view.php
8 -rw-r--r-- 1 root root 6022 Jun 28 2012 graph_xport.php
60 -rw-r--r-- 1 root root 60031 Jun 28 2012 host.php
20 -rw-r--r-- 1 root root 20031 Jun 28 2012 host_templates.php
4 drwxr-xr-x 2 root root 4096 Jul 25 13:42 images
4 drwxr-xr-x 4 cacti root 4096 Jul 25 13:50 include
4 -rw-r--r-- 1 root root 2313 Jun 28 2012 index.php
4 drwxr-xr-x 2 root root 4096 Jul 25 13:42 install
4 drwxr-xr-x 3 root root 4096 Jul 25 13:42 lib
0 lrwxrwxrwx 1 root root 15 Jul 25 13:42 log -> /var/log/cacti/
4 -rw-r--r-- 1 root root 2838 Jun 28 2012 logout.php
4 drwxr-xr-x 2 root root 4096 Jul 25 13:42 plugins
28 -rw-r--r-- 1 root root 27362 Jun 28 2012 plugins.php
8 -rw-r--r-- 1 root root 4310 Jun 28 2012 poller_commands.php
4 -rw-r--r-- 1 root root 2243 Jun 28 2012 poller_export.php
20 -rwxr-xr-x 1 root root 18056 Jun 28 2012 poller.php
4 drwxr-xr-x 5 root root 4096 Jul 25 13:42 resource
**0 lrwxrwxrwx 1 cacti cacti 18 Jul 25 13:42 rra -> /var/lib/cacti/rra**
8 -rw-r--r-- 1 root root 7394 Jun 28 2012 rra.php
0 lrwxrwxrwx 1 root root 22 Jul 25 13:42 scripts -> /var/lib/cacti/scripts
12 -rw-r--r-- 1 root root 10820 Jun 28 2012 script_server.php
8 -rw-r--r-- 1 root root 5761 Jun 28 2012 settings.php
4 -rw-r--r-- 1 root root 1407 Jun 3 2012 snmpv3_priv_proto_none.patch
8 -rw-r--r-- 1 root root 6345 Jun 28 2012 templates_export.php
8 -rw-r--r-- 1 root root 5835 Jun 28 2012 templates_import.php
20 -rw-r--r-- 1 root root 19529 Jun 28 2012 tree.php
44 -rw-r--r-- 1 root root 44997 Jun 28 2012 user_admin.php
68 -rw-r--r-- 1 root root 65635 Jun 28 2012 utilities.php
I also changed the owner of rra folder to cacti user like this:
ls -ls /var/lib/cacti/
total 12
4 drwxr-xr-x 2 root root 4096 Jul 25 13:42 cli
0 lrwxrwxrwx 1 root root 24 Jul 25 13:42 include -> /usr/share/cacti/include
0 lrwxrwxrwx 1 cacti root 20 Jul 25 13:42 lib -> /usr/share/cacti/lib
**4 drwxr-xr-x 2 cacti cacti 4096 Jun 28 2012 rra**
4 drwxr-xr-x 2 root root 4096 Jul 25 13:42 scripts
What should I do next?
Thanks a lot!
What worked for me was to go into System Utilities (bottom of console) and click on Rebuild Poller Cache.
The most common case of a missing RRD file in Cacti is a data source problem.
This probably means that the Cacti poller could not retrieve data from the host.
Check the status of the device in the device list, if it's "Unknown" and if you didn't fiddle around with the availability detection, it means that Cacti is unable to get an SNMP reply from the host. This could have different reasons:
Check SNMP connectivity between the Cacti host and the polled host (in your case, since both sides are the Cacti host, make sure snmpd is running and listening on the same port Cacti is trying to reach it (default 161).
Check the community string on both ends
if DNS is used make sure resolving is possible and successful on the Cacti host (less relevant for localhost, but still a good idea imho).
Check the datasource using debug mode to get some extra info (Devices ›› Localhost ›› Data Source List ›› Localhost - Logged in Users ›› Turn On Data Source Debug Mode) and also try to poll the host using snmpget or snmpwalk:
snmpget -cCOMMUNITY -vVERSION HOSTNAME OID
I usually use snmpwalk which uses the same syntax:
snmpwalk -cpublic -v2c localhost 1.3.6.1.2.1
1.3.6.1.2.1 is for MIB-2
Further debugging help: Great guide by gandalf from the Cacti forums
Cacti forums, where you can try and post your question there.
Good luck!
Check your permissions. I had the same issue when I stood up a cacti instance on Debian. Everything was displaying correctly except for the graphs, and I had the same "No such file or directory" errors. Changing the ownership of the rra directory to cacti:www-data resolved the issue for me.
Good luck.