Bug #944
Cannot load lookups with some meta-data
100%
Description
Try with local.meta that looks like this (even the file is not in the users directory):
[lookups/test_case_import.csv] owner = admin version = 6.2.1 modtime = 1422085232.405032000
History
#1 Updated by Luke Murphey almost 10 years ago
The problem is in the following:
- resolve_lookup_filename: fails to look at the path as provided by Splunk in that path variable
- getBackupDirectory: does not properly resolve the backup directory
#2 Updated by Luke Murphey almost 10 years ago
- Target version set to 1.4.1
#3 Updated by Luke Murphey almost 10 years ago
- Status changed from New to In Progress
#4 Updated by Luke Murphey almost 10 years ago
- % Done changed from 0 to 50
#5 Updated by Luke Murphey almost 10 years ago
Need to make sure that the saving doesn't put the file in the user's directory.
#6 Updated by Luke Murphey almost 10 years ago
- Status changed from In Progress to Closed
- % Done changed from 50 to 100
#7 Updated by Luke Murphey almost 10 years ago
Steps to repro:
- Make a lookup file (with owner as nobody)
- Define meta-data to re-assign the owner (see below)
- Restart Splunk
- Attempt to edit the lookup. Note that it either doesn't load and/or backups are not stored in the correct directory.
The meta-data should look something like this:
[lookups/test_perms.csv] access = read : [ * ], write : [ admin ] export = none owner = luke
#8 Updated by Luke Murphey almost 10 years ago
This seems to be working but with some odd behavior.
If you attempt to load a lookup file in the editor it will open it within the context of the user. This causes a copy to be made in the users' directory.
#9 Updated by Luke Murphey almost 10 years ago
Need to verify that the export works appropriately too.
#10 Updated by Luke Murphey almost 10 years ago
- Status changed from Closed to In Progress
- % Done changed from 100 to 90
#11 Updated by Luke Murphey almost 10 years ago
This seems to be working now. The main issue occurs when the lookup file has an user as an owner but the file is in a the apps directory, not the user's directory. Basically, I'm now detecting this state and including or excluding the owner when calling save accordingly so that another lookup copy doesn't get made.
#12 Updated by Luke Murphey almost 10 years ago
- Status changed from In Progress to Closed
- % Done changed from 90 to 100