Demo Discussion
Forum Config Examples Contributions Vulnerabilities
  Discussion forum about ELOG, Page 771 of 806  Not logged in ELOG logo
    icon5.gif   Re: do some changes on .CFG, posted by Andreas Luedeke on Wed Aug 19 15:22:58 2020 

How are we supposed to give you a hint when you don't post your configuration?

Lahreche Abdelmadjid wrote:

Thanks, but I'm the Admin of local ELOG.

usually I can make a lot of changes on my files .CFG But this time no way.

when I select one of the choice i've a text who appear with the right text (code), but only with this choice "Permis de verouillage et d'étiquetage 016685-68AF-0031"

the text appeared is false.

Andreas Luedeke wrote:

This has nothing to do with the ELOG package, but only with your local configuration of that specific logbook.
You should contact your local ELOG administrator.

Or you might want to rephrase you question: do you want to have this text added in the text field when selecting the field specifier?
How that can be done depends on your specific configuration. Since you are apparently already using a form in the text field, it might be tricky.

Lahreche Abdelmadjid wrote:

Hi All,

I would like to have "Permis de verouillage et d'étiquetage 016685-68AF-0031" when I select it.

I don't found where can I make this change

thank you.

 

 

 

 

 

    icon2.gif   Re: field selections persist across new log entries?, posted by Andreas Luedeke on Wed Sep 9 10:33:58 2020 
It is probably possible, but requires a big of a hack.
Whenever you save a new entry or edit an old one, you run a little shell script to write the value of this field into a file.
Whenever you create a new entry you read the PRESET value with a shell script from that file.

Here are the relevant excepts from the documentation:

Subst <attribute> = <string>
When submitting logbook entries, attribute values can be substituted by some text. This text can contain arbitrary fixed text and following values:

  • $<attribute>: The entered value of the attribute itself
  • $host: The host name where elogd is running
  • $remote_host: The host name of the host from with the entry was submitted
  • $short_name: The login name (if password file is present)
  • $long_name: The full name from the password file for the current user
  • $user_email: The email address from the password file for the current user
  • $logbook: The name of the current logbook
  • $date: The current date, formatted via "Date format"
  • $utcdate: The current UTC date (GMT) and time, formatted via "Date format"
  • $version: The version of the ELOG server in the form x.y.z
  • $revision: The Subversion reversion of the ELOG server as an integer number
  • $shell(<command>): <command> gets passed to the operating system shell and the result is taken for substitution.

Execute new | edit | delete = <command>
It is possible to execute a shell command on the server side after a new message has been submitted, edited or deleted. This feature has been used in the past for SMS notifications over a telephone system and for synchrnonization of the ELOG database with an external SQL database. The <command> can contain substitutions similar to the Subst command. In addition the list of all attachments can be referred to via $<attachments>. The text body of the entry can be referred to with $text. It should be noted that only the first 1500 characters of the text can be used, in order not to exceed the limits of the shell. Following (Unix) command writes a notification into some file:

Execute new = echo "New message wiht ID $message id of type $type from $long_name on $remote_host" >> /tmp/elog.log


It should be noted that this feature can impose a security problem. If someone can edit the elogd.cfg through the Config command of elogd, that person can put malicious code into elogd.cfg and execute it. This is even more severe if elogd runs with root privileges. To avoid such problems, the execute facility is disabled in elogd by default and has to be enabled explicitly with the "-x" command line flag. The administrator has to ensure then of course that only trusted people can edit elogd.cfg.

 

Have fun!

Andreas

Anthony Krishock wrote:

All,

 

I am using elog as an observation log for amateur astronomy. I have a form configured, but I would like to know if it is possible to make certain fields persist across new entries.

What I mean is this:

When I make an new observation, I select a value for sky conditions (say.. "1"). When I make another observation, "1" is already selected.

Is this possible? If so, how?

Thanks

 

    icon2.gif   Re: Insert images slow downs the ELOG, posted by Andreas Luedeke on Sat Sep 12 19:19:02 2020 

I found the most limiting factor of ELOG to be the file access. ELOG stores all entries in files and therefore has a lot of disk access.

We found that an AFS directory for ELOG is unusable. We tried to store our logbooks on NFS, and it was barely usable but slow. Now we use a local disk on the server, that works fine.

If you want to speed up ELOG the best approach is a dedicated server with a local SSD storage.

Zbigniew Reszela wrote:

Dear all,

First, many thanks for creating and sharing this great tool which is ELOG! Our users are very happy with it!

I have few questions about inserting images into the entries.

From time to time our users insert them directly in the editor what leads to encoding the whole image in the HTML log file and the images does not appear in the attachments list. Saving and further editing of such entries slows down the whole ELOG server which uses 100% of CPU.

I'm not sure how they do it Ctrl+C & Ctrl+V, drag & drop, etc.. What I know is that if they add it using the "Insert image" action in the editor there are no problems and the images are properly listed in the attachments.

I read in the docs:

uploading or downloading an attachement file is a single request, and causes the entire file to be loaded in server memory while the request is being processed.
This is not normally a problem for the sort of short, text-mode entries ELOG is designed to support. However, if a user starts to upload or download a large attachment file (or image) over a slow link, all other users on that ELOG server will have to wait for that transfert to finish before they can access any logbook on that server. This is why there is a low limit on the size of attachments, and why ELOG should not be used to distribute large files under intensive multi-user conditions.

but I think this is not our case. Here I talk about wrongly inserting a single image of 700KiB.

So, I'm asking:

  1. Is the behavior that we observe something already detected? If yes, which are exactly the wrong ways of inserting the images?
  2. Is it fixed in newer ELOG versions?
  3. Is it possible to disable the wrong ways of inserting the images in order to avoid such problems?

Many thanks in advance for your help!

 

    icon2.gif   Re: view connecting account, posted by Andreas Luedeke on Mon Sep 14 17:25:08 2020 

Yes, you can see that in the logging file, if you turn on logging. You might want to read the manual https://elog.psi.ch/elog/config.html. Here's the relevant excerpt:

  • Logfile = <file>
    This option specifies a filename which logs all login/logout activities and successful user connections for logbooks with user level access. The the logging level (see below) is larger than 1, also read and write accesses can be logged.
  • Logging level = 1 | 2 | 3
    Specifies the logging level. The higher this value, the more information is logged. Default is 2:
    • 1: Log only logins and logouts
    • 2: Log also write accesses
    • 3: Log also read accesses
Lahreche Abdelmadjid wrote:

Hi All,

Can I view who is connected to ELOG (I'm the Admin) ?

thank you.

 

    icon3.gif   Re: Query to get values for Attributes, posted by Andreas Luedeke on Mon Sep 21 20:03:49 2020 

That would be a nice feature...

If you are good in parsing HTML you can achieve this feature: when you create a new entry "<elog-URL>?cmd=new", you'll get HTML source code that provides you with all possible attribute choices.

Disclaimer: this only works if you don't use Conditional attributes.

Florian Feldbauer wrote:

Hey,

I'm trying to integrate the Elog into our SlowControl System (Phoebus/EPICS). As a first step I translated the python library to Java. So writing new Entries and viewing them works.
But for Phoebus, you need a list of the possible values for the attributes. Currently this is done via the config file from Phoebus.

Is there a way to get the values also via a query directly from the Elog?

Cheers,
Florian

 

    icon2.gif   Re: moving eLog to another computer, posted by Andreas Luedeke on Sat Oct 3 11:08:27 2020 
  • you need to copy your logbooks into the "logbooks" directory.
  • you need to copy your elog.cfg logbook config file to the new elog folder and reference it at start-up (something like "elogd -c /usr/local/elog/elogd.cfg ...")

Some people modify other stuff (CSS, java scripts) but if you had you would know what you did.

If the old ELOG was a 2.x version and the new is 3.x, then on the first start-up all logbook data files are copied into sub-folders for each year.
This is only done (automatically) during the first start-up, afterwards you can not use a 2.x version anymore (you won't want that anyway).

Ekaterina Korobkina wrote:

Our Unix server died, so we decided to move our old eLog to the new server, running Mac OSX. Elog version is earlier then 2013, I can not say

I read that on OSX  eLog must be intalled through "make" command

if I need to install eLog first, how to add all old information later?

 

 

    icon2.gif   Re: Field values dependent on other selections, posted by Andreas Luedeke on Fri Oct 23 15:10:54 2020 

Instead of using three different options you could use the same:

Options Eyepiece = Pentax{a}, TeleVue{b}, Meade{c}

{a} Options Form = 5mm, 20mm, 30mm
{b} Options Form = 7mm Nagler, 10mm Radian, 24mm Panoptic
{c} Options Form = 8.8mm UWA, 14mm UWA, 26mm QX

It makes more sense.
But it is as well possible to supress attributed in the edit from. See

  • Show Attributes = <list>
    Attributes present in this list are shown in the single entry page. Omitting attributes can make sense for attributes which are automatically derived from other attributes via the Change <attribute> command.
  • Show Attributes Edit = <list>
    The same as Show Attributes, but for the entry form.

You just have a different <list> for each conditional case {a} {b} {c}.

Anthony Krishock wrote:

Thanks for your suggestion. Right now, my log is configured as follows:

Options Eyepiece = Pentax{a}, TeleVue{b}, Meade{c}
{a} Options Pentax = 5mm, 20mm, 30mm
{b} Options TeleVue = 7mm Nagler, 10mm Radian, 24mm Panoptic
{c} Options Meade = 8.8mm UWA, 14mm UWA, 26mm QX

If I select "Pentax", I would like the other two options to be unavailable. Instead, all three options are shown. Can I mask the other unused options?

Stefan Ritt wrote:

Look in the manual under "conditional attributes"

Stefan

Anthony Krishock wrote:

All,

I would like to know if there is a way in elog to populate a field based on the value of another field. What I want to do is have a field with a few selections (a menu) and another text field that populates based on what I select from the menu.

 

Is this possible?

 

 

 

    icon2.gif   Re: Create entry from command line - override Date?, posted by Andreas Luedeke on Tue Oct 27 17:07:00 2020 

You could transform your entries into the ELOG file format (either XML or CSV) and then use the import function. That would upload the correct dates from your entries.

If you use the "Orig Date" trick you've proposed, you'll see that datetime fields are stored as seconds of the epoch (since 1.1.1970). Not so easy to copy and paste them, but you can convert them with a script.

Cheers, Andreas

David Wallis wrote:

Hi Stefan, thanks! Does the Date field need to be the first field in each entry? I can see adding a "termpory" field called "Orig Date", upload the old entries, then edit the file(s), delete the Date field, and rename Orig Date to Date. Will that work?

Stefan Ritt wrote:

You have to manually manipulate the logbook files YYMMDDa.log where you find the date at the top like:

MID@$: 1
Date: Wed, 02 Sep 2020 15:38:09 +0300 <==== change here !!!!
Author: Stefan
Type: General
Category: 
Subject: CURL test
Attachment: 
Encoding: plain
========================================
Text body
 

 

 

ELOG V3.1.5-3fb85fa6