Is it safe to run sstableverify against live sstables? [closed] - cassandra

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 5 years ago.
Improve this question
Is it safe to run sstableverify against live sstables while Cassandra is running?
After and while running sstableverify in a lab, I cannot find anything in any logs that would indicate a problem.

SSTables are immutable by nature, so you can work with them using the same user that runs Cassandra (see comment for explanation). If you want to prevent their disappearance because of compaction, you may take the snapshot that will create hard links to files (but don't forget to remove snapshot later).

Safe maybe... But, you may run into the disappearance of sstables, due to compaction (something else mabye), while running sstableverify. Use nodetool verify instead for live data. Use sstableverify for data on offline recovery systems to verify data.

Related

Which compaction strategy is recommended for a table with minimal updates [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 1 year ago.
Improve this question
I am looking for compaction strategy for the data which has following characteristics
We don't need the data after 60-90 days. At extreme scenarios maybe 180 days.
Ideally insert happens and updates never happens but it is realistic to expect duplicate events which cause updates.
It is indirectly time series data if you think about it, events coming first will be stored first and once the event is stored its almost never modified unless duplicate events are published.
Which strategy will be best for this case?
TimeWindowCompactionStrategy is only suitable for timeseries use cases and is the only reason you'd choose TWCS.
LeveledCompactionStrategy has very limited edge cases and the time I spend helping users troubleshoot LCS because it doesn't suit their needs is hardly worth the supposed benefits.
Unless you have some very specific requirements, SizeTieredCompactionStrategy is almost always the right choice and the reason it is the default compaction strategy. Cheers!

How to clean the data from tables which are created from old snapshots [closed]

Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 3 years ago.
Improve this question
I will restore snapshot from sandbox instance to my local instance for every one week, when i restore the snapshot the data in the table with unwanted companyIDs are still exists, as these data is not useful, so, how can i delete the data from table with unwanted companyIDs, is it ok if i run a delete script, or is their any better way to do, please suggest.
You can use the pp_DeleteCompany stored procedure to delete the orphan snapshots and records. Example: EXEC pp_DeleteCompany -1234567 (assuming the CompanyID is -1234567)

what is the best practice for multiple threads writing to one file [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 6 years ago.
Improve this question
I'm writing a multi-threaded program and all these threads should write their data to a single file.
these threads only writing different strings for some kind of append-only logging
whats the best practice for sharing a file between threads for out put?
For logging (for future questions, make sure you put that information into the question rather than just a comment) there's a strong preference to not have the threads do file access they don't have to; as it means that logging negatively impacts performance for the rest of that thread.
For that reason, NathanOliver's suggestion of having the threads write to a shared container and then one dedicated to dumping that container to file would probably be the best option for you.

Will the Nest API support reading the state of the system? [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 8 years ago.
Improve this question
The API doesn't give any information on the state of the HVAC system, i.e. heating, cooling, fan. Will this be added in the future?
You can determine the cooling/heating mode using the "hvac_mode" property (https://developer.nest.com/documentation/api#hvac_mode), and "fan_timer_active" to check if the fan timer is running. You can also query the target properties, starting with "target_temperature_f" (https://developer.nest.com/documentation/api#target_temperature_f)
No, HVAC mode isn't the same as HVAC state. My system could be in cooling mode but not actively making a call for cooling. If you know the swing value you can guess based on the difference between set point and actual temp but that really isn't reliable.
Presumably this might be to prevent replication of existing Nest functionality?

Size of access.log and server load? [closed]

Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 10 years ago.
Improve this question
Is there any difference at all in server load when adding new lines to a big vs. small access.log file?
What I mean is, should I delete my access.log files if they become too big or leave it. It is 6GB right now. I do not rotate.
I'm not sure about the performance difference of big or small files, but maybe you want to split them every month and compress old access-log files. For that you can use logrotate. More information in the man page
Log rotation is an important part of maintaining a server. Without it, you'r likely to fill up your disk, and then your server will behave extremely strangely, depending on the app.
Regardless of performance, you should be using logrotate or something similar.

Resources